| OLD | NEW |
| 1 ; Tests the Subzero "name mangling" when using the "llvm2ice --prefix" | 1 ; Tests the Subzero "name mangling" when using the "llvm2ice --prefix" |
| 2 ; option. | 2 ; option. |
| 3 | 3 |
| 4 ; RUN: %llvm2ice --verbose none %s | FileCheck %s | 4 ; RUN: %llvm2ice --verbose none %s | FileCheck %s |
| 5 ; RUN: %llvm2ice --verbose none --prefix Subzero %s | FileCheck --check-prefix=M
ANGLE %s | 5 ; RUN: %llvm2ice --verbose none --prefix Subzero %s | FileCheck --check-prefix=M
ANGLE %s |
| 6 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s | 6 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s |
| 7 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s | 7 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s |
| 8 ; RUN: %llvm2iceinsts --pnacl %s | %szdiff %s \ | 8 ; RUN: %llvm2iceinsts --pnacl %s | %szdiff %s \ |
| 9 ; RUN: | FileCheck --check-prefix=DUMP %s | 9 ; RUN: | FileCheck --check-prefix=DUMP %s |
| 10 | 10 |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 define internal void @_Z-1FuncCPlusPlusi(i32 %i) { | 98 define internal void @_Z-1FuncCPlusPlusi(i32 %i) { |
| 99 entry: | 99 entry: |
| 100 ret void | 100 ret void |
| 101 } | 101 } |
| 102 ; MANGLE: Subzero_Z-1FuncCPlusPlusi: | 102 ; MANGLE: Subzero_Z-1FuncCPlusPlusi: |
| 103 | 103 |
| 104 | 104 |
| 105 ; Test for substitution incrementing. This single test captures: | 105 ; Test for substitution incrementing. This single test captures: |
| 106 ; S<num>_ ==> S<num+1>_ for single-digit <num> | 106 ; S<num>_ ==> S<num+1>_ for single-digit <num> |
| 107 ; S_ ==> S0_ | 107 ; S_ ==> S0_ |
| 108 ; String length increase, e.g. SZZZ_ ==> S0000_ | 108 ; String length increase, e.g. SZZZ_ ==> S1000_ |
| 109 ; At least one digit wrapping without length increase, e.g. SZ9ZZ_ ==> SZA00_ | 109 ; At least one digit wrapping without length increase, e.g. SZ9ZZ_ ==> SZA00_ |
| 110 ; Unrelated identifiers containing S[0-9A-Z]* , e.g. MyClassS1x | 110 ; Unrelated identifiers containing S[0-9A-Z]* , e.g. MyClassS1x |
| 111 ; A proper substring of S<num>_ at the end of the string | 111 ; A proper substring of S<num>_ at the end of the string |
| 112 ; (to test parser edge cases) | 112 ; (to test parser edge cases) |
| 113 | 113 |
| 114 define internal void @_Z3fooP10MyClassS1xP10MyClassS2xRS_RS1_S_S1_SZZZ_SZ9ZZ_S12
345() { | 114 define internal void @_Z3fooP10MyClassS1xP10MyClassS2xRS_RS1_S_S1_SZZZ_SZ9ZZ_S12
345() { |
| 115 ; MANGLE: _ZN7Subzero3fooEP10MyClassS1xP10MyClassS2xRS0_RS2_S0_S2_S0000_SZA00_
S12345: | 115 ; MANGLE: _ZN7Subzero3fooEP10MyClassS1xP10MyClassS2xRS0_RS2_S0_S2_S1000_SZA00_
S12345: |
| 116 entry: | 116 entry: |
| 117 ret void | 117 ret void |
| 118 } | 118 } |
| 119 | 119 |
| 120 ; Test that unmangled (non-C++) strings don't have substitutions updated. | 120 ; Test that unmangled (non-C++) strings don't have substitutions updated. |
| 121 define internal void @foo_S_S0_SZ_S() { | 121 define internal void @foo_S_S0_SZ_S() { |
| 122 ; MANGLE: Subzerofoo_S_S0_SZ_S: | 122 ; MANGLE: Subzerofoo_S_S0_SZ_S: |
| 123 entry: | 123 entry: |
| 124 ret void | 124 ret void |
| 125 } | 125 } |
| 126 | 126 |
| 127 ; ERRORS-NOT: ICE translation error | 127 ; ERRORS-NOT: ICE translation error |
| 128 ; DUMP-NOT: SZ | 128 ; DUMP-NOT: SZ |
| OLD | NEW |