diff options
Diffstat (limited to 'recipes-devtools/binutils/files/bin.e500mc_nop.patch')
| -rw-r--r-- | recipes-devtools/binutils/files/bin.e500mc_nop.patch | 114 |
1 files changed, 114 insertions, 0 deletions
diff --git a/recipes-devtools/binutils/files/bin.e500mc_nop.patch b/recipes-devtools/binutils/files/bin.e500mc_nop.patch new file mode 100644 index 0000000..9c9d52c --- /dev/null +++ b/recipes-devtools/binutils/files/bin.e500mc_nop.patch | |||
| @@ -0,0 +1,114 @@ | |||
| 1 | Generate the preferred NOP: ori r0, r0, 0 in the place of ori r2, r2, 0 | ||
| 2 | and add the nop test cases in gas for e500mc64, e5500 and e6500. | ||
| 3 | |||
| 4 | diff -ruN binutils-4.6.0-orig/gas/config/tc-ppc.c binutils-4.6.0-new/gas/config/tc-ppc.c | ||
| 5 | --- binutils-4.6.0-orig/gas/config/tc-ppc.c 2011-08-18 16:02:21.847979825 -0500 | ||
| 6 | +++ binutils-4.6.0-new/gas/config/tc-ppc.c 2011-08-19 10:09:19.888849978 -0500 | ||
| 7 | @@ -5815,8 +5817,14 @@ | ||
| 8 | } | ||
| 9 | |||
| 10 | if ((ppc_cpu & PPC_OPCODE_POWER7) != 0) | ||
| 11 | - /* power7 group terminating nop: "ori 2,2,0". */ | ||
| 12 | - md_number_to_chars (dest, 0x60420000, 4); | ||
| 13 | + { | ||
| 14 | + if (ppc_cpu & PPC_OPCODE_E500MC) | ||
| 15 | + /* e500mc group terminating nop: "ori 0,0,0". */ | ||
| 16 | + md_number_to_chars (dest, 0x60000000, 4); | ||
| 17 | + else | ||
| 18 | + /* power7 group terminating nop: "ori 2,2,0". */ | ||
| 19 | + md_number_to_chars (dest, 0x60420000, 4); | ||
| 20 | + } | ||
| 21 | else | ||
| 22 | /* power6 group terminating nop: "ori 1,1,0". */ | ||
| 23 | md_number_to_chars (dest, 0x60210000, 4); | ||
| 24 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e500mc64_nop.d binutils-4.6.0-new/gas/testsuite/gas/ppc/e500mc64_nop.d | ||
| 25 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e500mc64_nop.d 1969-12-31 18:00:00.000000000 -0600 | ||
| 26 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e500mc64_nop.d 2011-08-19 10:16:29.561849966 -0500 | ||
| 27 | @@ -0,0 +1,13 @@ | ||
| 28 | +#as: -mppc -me500mc64 | ||
| 29 | +#objdump: -dr -Me500mc64 | ||
| 30 | +#name: Power E500MC64 nop tests | ||
| 31 | + | ||
| 32 | +.*: +file format elf(32)?(64)?-powerpc.* | ||
| 33 | + | ||
| 34 | +Disassembly of section \.text: | ||
| 35 | + | ||
| 36 | +0+00 <start>: | ||
| 37 | + 0: 60 00 00 00 nop | ||
| 38 | + 4: 60 00 00 00 nop | ||
| 39 | + 8: 60 00 00 00 nop | ||
| 40 | + c: 60 00 00 00 nop | ||
| 41 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e500mc64_nop.s binutils-4.6.0-new/gas/testsuite/gas/ppc/e500mc64_nop.s | ||
| 42 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e500mc64_nop.s 1969-12-31 18:00:00.000000000 -0600 | ||
| 43 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e500mc64_nop.s 2011-08-19 10:16:29.561849966 -0500 | ||
| 44 | @@ -0,0 +1,5 @@ | ||
| 45 | +# Power E500MC64 nop tests | ||
| 46 | + .section ".text" | ||
| 47 | +start: | ||
| 48 | + nop | ||
| 49 | + .p2align 4,,15 | ||
| 50 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e5500_nop.d binutils-4.6.0-new/gas/testsuite/gas/ppc/e5500_nop.d | ||
| 51 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e5500_nop.d 1969-12-31 18:00:00.000000000 -0600 | ||
| 52 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e5500_nop.d 2011-08-19 10:16:29.561849966 -0500 | ||
| 53 | @@ -0,0 +1,13 @@ | ||
| 54 | +#as: -mppc -me5500 | ||
| 55 | +#objdump: -dr -Me5500 | ||
| 56 | +#name: Power E5500 nop tests | ||
| 57 | + | ||
| 58 | +.*: +file format elf(32)?(64)?-powerpc.* | ||
| 59 | + | ||
| 60 | +Disassembly of section \.text: | ||
| 61 | + | ||
| 62 | +0+00 <start>: | ||
| 63 | + 0: 60 00 00 00 nop | ||
| 64 | + 4: 60 00 00 00 nop | ||
| 65 | + 8: 60 00 00 00 nop | ||
| 66 | + c: 60 00 00 00 nop | ||
| 67 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e5500_nop.s binutils-4.6.0-new/gas/testsuite/gas/ppc/e5500_nop.s | ||
| 68 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e5500_nop.s 1969-12-31 18:00:00.000000000 -0600 | ||
| 69 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e5500_nop.s 2011-08-19 10:16:29.561849966 -0500 | ||
| 70 | @@ -0,0 +1,5 @@ | ||
| 71 | +# Power E5500 nop tests | ||
| 72 | + .section ".text" | ||
| 73 | +start: | ||
| 74 | + nop | ||
| 75 | + .p2align 4,,15 | ||
| 76 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e6500_nop.d binutils-4.6.0-new/gas/testsuite/gas/ppc/e6500_nop.d | ||
| 77 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e6500_nop.d 1969-12-31 18:00:00.000000000 -0600 | ||
| 78 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e6500_nop.d 2011-08-19 10:16:29.561849966 -0500 | ||
| 79 | @@ -0,0 +1,13 @@ | ||
| 80 | +#as: -mppc -me6500 | ||
| 81 | +#objdump: -dr -Me6500 | ||
| 82 | +#name: Power E6500 nop tests | ||
| 83 | + | ||
| 84 | +.*: +file format elf(32)?(64)?-powerpc.* | ||
| 85 | + | ||
| 86 | +Disassembly of section \.text: | ||
| 87 | + | ||
| 88 | +0+00 <start>: | ||
| 89 | + 0: 60 00 00 00 nop | ||
| 90 | + 4: 60 00 00 00 nop | ||
| 91 | + 8: 60 00 00 00 nop | ||
| 92 | + c: 60 00 00 00 nop | ||
| 93 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/e6500_nop.s binutils-4.6.0-new/gas/testsuite/gas/ppc/e6500_nop.s | ||
| 94 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/e6500_nop.s 1969-12-31 18:00:00.000000000 -0600 | ||
| 95 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/e6500_nop.s 2011-08-19 10:16:29.562849956 -0500 | ||
| 96 | @@ -0,0 +1,5 @@ | ||
| 97 | +# Power E6500 nop tests | ||
| 98 | + .section ".text" | ||
| 99 | +start: | ||
| 100 | + nop | ||
| 101 | + .p2align 4,,15 | ||
| 102 | diff -ruN binutils-4.6.0-orig/gas/testsuite/gas/ppc/ppc.exp binutils-4.6.0-new/gas/testsuite/gas/ppc/ppc.exp | ||
| 103 | --- binutils-4.6.0-orig/gas/testsuite/gas/ppc/ppc.exp 2011-08-19 10:15:29.445978575 -0500 | ||
| 104 | +++ binutils-4.6.0-new/gas/testsuite/gas/ppc/ppc.exp 2011-08-19 10:16:17.827852501 -0500 | ||
| 105 | @@ -43,6 +43,9 @@ | ||
| 106 | run_dump_test "ppc750ps" | ||
| 107 | run_dump_test "e500mc" | ||
| 108 | run_dump_test "e6500" | ||
| 109 | + run_dump_test "e500mc64_nop" | ||
| 110 | + run_dump_test "e5500_nop" | ||
| 111 | + run_dump_test "e6500_nop" | ||
| 112 | run_dump_test "a2" | ||
| 113 | run_dump_test "cell" | ||
| 114 | run_dump_test "common" | ||
