OLD | NEW |
---|---|
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
45 | 45 |
46 #ifndef V8_INTERPRETED_REGEXP | 46 #ifndef V8_INTERPRETED_REGEXP |
47 #if V8_TARGET_ARCH_IA32 | 47 #if V8_TARGET_ARCH_IA32 |
48 #include "ia32/regexp-macro-assembler-ia32.h" | 48 #include "ia32/regexp-macro-assembler-ia32.h" |
49 #elif V8_TARGET_ARCH_X64 | 49 #elif V8_TARGET_ARCH_X64 |
50 #include "x64/regexp-macro-assembler-x64.h" | 50 #include "x64/regexp-macro-assembler-x64.h" |
51 #elif V8_TARGET_ARCH_ARM | 51 #elif V8_TARGET_ARCH_ARM |
52 #include "arm/regexp-macro-assembler-arm.h" | 52 #include "arm/regexp-macro-assembler-arm.h" |
53 #elif V8_TARGET_ARCH_MIPS | 53 #elif V8_TARGET_ARCH_MIPS |
54 #include "mips/regexp-macro-assembler-mips.h" | 54 #include "mips/regexp-macro-assembler-mips.h" |
55 #elif V8_TARGET_ARCH_SH4 | |
56 #include "sh4/regexp-macro-assembler-sh4.h" | |
55 #else | 57 #else |
56 #error Unsupported target architecture. | 58 #error Unsupported target architecture. |
57 #endif | 59 #endif |
58 #endif | 60 #endif |
59 | 61 |
60 #include "interpreter-irregexp.h" | 62 #include "interpreter-irregexp.h" |
61 | 63 |
62 | 64 |
63 namespace v8 { | 65 namespace v8 { |
64 namespace internal { | 66 namespace internal { |
(...skipping 6060 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
6125 #if V8_TARGET_ARCH_IA32 | 6127 #if V8_TARGET_ARCH_IA32 |
6126 RegExpMacroAssemblerIA32 macro_assembler(mode, (data->capture_count + 1) * 2, | 6128 RegExpMacroAssemblerIA32 macro_assembler(mode, (data->capture_count + 1) * 2, |
6127 zone); | 6129 zone); |
6128 #elif V8_TARGET_ARCH_X64 | 6130 #elif V8_TARGET_ARCH_X64 |
6129 RegExpMacroAssemblerX64 macro_assembler(mode, (data->capture_count + 1) * 2, | 6131 RegExpMacroAssemblerX64 macro_assembler(mode, (data->capture_count + 1) * 2, |
6130 zone); | 6132 zone); |
6131 #elif V8_TARGET_ARCH_ARM | 6133 #elif V8_TARGET_ARCH_ARM |
6132 RegExpMacroAssemblerARM macro_assembler(mode, (data->capture_count + 1) * 2, | 6134 RegExpMacroAssemblerARM macro_assembler(mode, (data->capture_count + 1) * 2, |
6133 zone); | 6135 zone); |
6134 #elif V8_TARGET_ARCH_MIPS | 6136 #elif V8_TARGET_ARCH_MIPS |
6135 RegExpMacroAssemblerMIPS macro_assembler(mode, (data->capture_count + 1) * 2, | 6137 RegExpMacroAssemblerMIPS macro_assembler(mode, (data->capture_count + 1) * 2); |
6136 zone); | 6138 #elif V8_TARGET_ARCH_SH4 |
Jakob Kummerow
2012/11/07 11:18:24
nit: let's keep the whitespace consistent
remi.duraffort
2012/11/07 11:59:26
Typo. Fixed in the next version of the patch
| |
6139 RegExpMacroAssemblerSH4 macro_assembler(mode, (data->capture_count + 1) * 2, | |
6140 zone); | |
6137 #endif | 6141 #endif |
6138 | 6142 |
6139 #else // V8_INTERPRETED_REGEXP | 6143 #else // V8_INTERPRETED_REGEXP |
6140 // Interpreted regexp implementation. | 6144 // Interpreted regexp implementation. |
6141 EmbeddedVector<byte, 1024> codes; | 6145 EmbeddedVector<byte, 1024> codes; |
6142 RegExpMacroAssemblerIrregexp macro_assembler(codes, zone); | 6146 RegExpMacroAssemblerIrregexp macro_assembler(codes, zone); |
6143 #endif // V8_INTERPRETED_REGEXP | 6147 #endif // V8_INTERPRETED_REGEXP |
6144 | 6148 |
6145 // Inserted here, instead of in Assembler, because it depends on information | 6149 // Inserted here, instead of in Assembler, because it depends on information |
6146 // in the AST that isn't replicated in the Node structure. | 6150 // in the AST that isn't replicated in the Node structure. |
(...skipping 12 matching lines...) Expand all Loading... | |
6159 } | 6163 } |
6160 | 6164 |
6161 return compiler.Assemble(¯o_assembler, | 6165 return compiler.Assemble(¯o_assembler, |
6162 node, | 6166 node, |
6163 data->capture_count, | 6167 data->capture_count, |
6164 pattern); | 6168 pattern); |
6165 } | 6169 } |
6166 | 6170 |
6167 | 6171 |
6168 }} // namespace v8::internal | 6172 }} // namespace v8::internal |
OLD | NEW |