Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1021)

Side by Side Diff: src/arm/constants-arm.h

Issue 14188016: ARM: clean up code now that ARMv6 is the baseline. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/code-stubs-arm.cc ('k') | src/arm/cpu-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 15 matching lines...) Expand all
26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 27
28 #ifndef V8_ARM_CONSTANTS_ARM_H_ 28 #ifndef V8_ARM_CONSTANTS_ARM_H_
29 #define V8_ARM_CONSTANTS_ARM_H_ 29 #define V8_ARM_CONSTANTS_ARM_H_
30 30
31 // ARM EABI is required. 31 // ARM EABI is required.
32 #if defined(__arm__) && !defined(__ARM_EABI__) 32 #if defined(__arm__) && !defined(__ARM_EABI__)
33 #error ARM EABI support is required. 33 #error ARM EABI support is required.
34 #endif 34 #endif
35 35
36 // This means that interwork-compatible jump instructions are generated. We
37 // want to generate them on the simulator too so it makes snapshots that can
38 // be used on real hardware.
39 #if defined(__THUMB_INTERWORK__) || !defined(__arm__)
40 # define USE_THUMB_INTERWORK 1
41 #endif
42
43 #if defined(__ARM_ARCH_7A__) || \ 36 #if defined(__ARM_ARCH_7A__) || \
44 defined(__ARM_ARCH_7R__) || \ 37 defined(__ARM_ARCH_7R__) || \
45 defined(__ARM_ARCH_7__) 38 defined(__ARM_ARCH_7__)
46 # define CAN_USE_ARMV7_INSTRUCTIONS 1 39 # define CAN_USE_ARMV7_INSTRUCTIONS 1
47 #ifndef CAN_USE_VFP3_INSTRUCTIONS 40 #ifndef CAN_USE_VFP3_INSTRUCTIONS
48 # define CAN_USE_VFP3_INSTRUCTIONS 41 # define CAN_USE_VFP3_INSTRUCTIONS
49 #endif 42 #endif
50 #endif 43 #endif
51 44
52 #if defined(__ARM_ARCH_6__) || \ 45 // Simulator should support unaligned access by default.
53 defined(__ARM_ARCH_6J__) || \
54 defined(__ARM_ARCH_6K__) || \
55 defined(__ARM_ARCH_6Z__) || \
56 defined(__ARM_ARCH_6ZK__) || \
57 defined(__ARM_ARCH_6T2__) || \
58 defined(CAN_USE_ARMV7_INSTRUCTIONS)
59 # define CAN_USE_ARMV6_INSTRUCTIONS 1
60 #endif
61
62 #if defined(__ARM_ARCH_5__) || \
63 defined(__ARM_ARCH_5T__) || \
64 defined(__ARM_ARCH_5TE__) || \
65 defined(__ARM_ARCH_5TEJ__) || \
66 defined(CAN_USE_ARMV6_INSTRUCTIONS)
67 # define CAN_USE_ARMV5_INSTRUCTIONS 1
68 # define CAN_USE_THUMB_INSTRUCTIONS 1
69 #endif
70
71 // Simulator should support ARM5 instructions and unaligned access by default.
72 #if !defined(__arm__) 46 #if !defined(__arm__)
73 # define CAN_USE_ARMV5_INSTRUCTIONS 1
74 # define CAN_USE_THUMB_INSTRUCTIONS 1
75
76 # ifndef CAN_USE_UNALIGNED_ACCESSES 47 # ifndef CAN_USE_UNALIGNED_ACCESSES
77 # define CAN_USE_UNALIGNED_ACCESSES 1 48 # define CAN_USE_UNALIGNED_ACCESSES 1
78 # endif 49 # endif
79
80 #endif
81
82 // Using blx may yield better code, so use it when required or when available
83 #if defined(USE_THUMB_INTERWORK) || defined(CAN_USE_ARMV5_INSTRUCTIONS)
84 #define USE_BLX 1
85 #endif 50 #endif
86 51
87 namespace v8 { 52 namespace v8 {
88 namespace internal { 53 namespace internal {
89 54
90 // Constant pool marker. 55 // Constant pool marker.
91 // Use UDF, the permanently undefined instruction. 56 // Use UDF, the permanently undefined instruction.
92 const int kConstantPoolMarkerMask = 0xfff000f0; 57 const int kConstantPoolMarkerMask = 0xfff000f0;
93 const int kConstantPoolMarker = 0xe7f000f0; 58 const int kConstantPoolMarker = 0xe7f000f0;
94 const int kConstantPoolLengthMaxMask = 0xffff; 59 const int kConstantPoolLengthMaxMask = 0xffff;
(...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after
783 static int Number(const char* name, bool* is_double); 748 static int Number(const char* name, bool* is_double);
784 749
785 private: 750 private:
786 static const char* names_[kNumVFPRegisters]; 751 static const char* names_[kNumVFPRegisters];
787 }; 752 };
788 753
789 754
790 } } // namespace v8::internal 755 } } // namespace v8::internal
791 756
792 #endif // V8_ARM_CONSTANTS_ARM_H_ 757 #endif // V8_ARM_CONSTANTS_ARM_H_
OLDNEW
« no previous file with comments | « src/arm/code-stubs-arm.cc ('k') | src/arm/cpu-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698