12.07.2015 Views

RealView Compilation Tools コンパイラユーザガイド - ARM ...

RealView Compilation Tools コンパイラユーザガイド - ARM ...

RealView Compilation Tools コンパイラユーザガイド - ARM ...

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

NEON ベ ク ト ル 化 コ ンパイ ラの 使 用0x4546, 0x4d65, 0x5555, 0x5d10, 0x6492, 0x6bd5, 0x72d7, 0x7991,};int i, ok = 1;fn(r, sizeof(r)/sizeof(*r), x, y);for (i = 0; i < sizeof(r)/sizeof(*r); ++i){if (r[i] != expected[i]){printf("mismatch: r[%d] = 0x%04x; expected[%d] = 0x%04x\n", i, r[i], i, expected[i]);ok = 0;break;}}if (ok) printf("** TEST PASSED OK **\n");return ok ? 0 : 1;}#ifdef __TARGET_ARCH_7_A__asm void init_cpu(){// Set up CPU stateMRC p15,0,r4,c1,c0,0ORR r4,r4,#0x00400000 // enable unaligned mode (U=1)BIC r4,r4,#0x00000002 // disable alignment faults (A=0)// MMU not enabled: no page tablesMCR p15,0,r4,c1,c0,0#ifdef __BIG_ENDIANSETEND BE#endifMRC p15,0,r4,c1,c0,2 // Enable VFP access in the CAR -ORR r4,r4,#0x00f00000 // must be done before any VFP instructionsMCR p15,0,r4,c1,c0,2MOV r4,#0x40000000 // Set EN bit in FPEXCMSR FPEXC,r4IMPORT __mainB __main}#endif<strong>ARM</strong> DUI 0205IJ Copyright © 2002-2010 <strong>ARM</strong> Limited. All rights reserved. 3-23ID 100419Non-Confidential,

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!