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

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

Issue 9692048: MIPS: Added support for Loongson architectures. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 9 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/mips/code-stubs-mips.cc ('k') | src/mips/disasm-mips.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 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
11 // with the distribution. 11 // with the distribution.
(...skipping 20 matching lines...) Expand all
32 #ifdef DEBUG 32 #ifdef DEBUG
33 #define UNIMPLEMENTED_MIPS() \ 33 #define UNIMPLEMENTED_MIPS() \
34 v8::internal::PrintF("%s, \tline %d: \tfunction %s not implemented. \n", \ 34 v8::internal::PrintF("%s, \tline %d: \tfunction %s not implemented. \n", \
35 __FILE__, __LINE__, __func__) 35 __FILE__, __LINE__, __func__)
36 #else 36 #else
37 #define UNIMPLEMENTED_MIPS() 37 #define UNIMPLEMENTED_MIPS()
38 #endif 38 #endif
39 39
40 #define UNSUPPORTED_MIPS() v8::internal::PrintF("Unsupported instruction.\n") 40 #define UNSUPPORTED_MIPS() v8::internal::PrintF("Unsupported instruction.\n")
41 41
42 enum ArchVariants {
43 kMips32r2,
44 kMips32r1,
45 kLoongson
46 };
42 47
43 #ifdef _MIPS_ARCH_MIPS32R2 48 #ifdef _MIPS_ARCH_MIPS32R2
44 #define mips32r2 1 49 static const ArchVariants kArchVariant = kMips32r2;
50 #elif _MIPS_ARCH_LOONGSON
51 // The loongson flag refers to the LOONGSON architectures based on MIPS-III,
52 // which predates (and is a subset of) the mips32r2 and r1 architectures.
53 static const ArchVariants kArchVariant = kLoongson;
45 #else 54 #else
46 #define mips32r2 0 55 static const ArchVariants kArchVariant = kMips32r1;
47 #endif 56 #endif
48 57
49 58
50 #if(defined(__mips_hard_float) && __mips_hard_float != 0) 59 #if(defined(__mips_hard_float) && __mips_hard_float != 0)
51 // Use floating-point coprocessor instructions. This flag is raised when 60 // Use floating-point coprocessor instructions. This flag is raised when
52 // -mhard-float is passed to the compiler. 61 // -mhard-float is passed to the compiler.
53 const bool IsMipsSoftFloatABI = false; 62 const bool IsMipsSoftFloatABI = false;
54 #elif(defined(__mips_soft_float) && __mips_soft_float != 0) 63 #elif(defined(__mips_soft_float) && __mips_soft_float != 0)
55 // Not using floating-point coprocessor instructions. This flag is raised when 64 // Not using floating-point coprocessor instructions. This flag is raised when
56 // -msoft-float is passed to the compiler. 65 // -msoft-float is passed to the compiler.
(...skipping 723 matching lines...) Expand 10 before | Expand all | Expand 10 after
780 const int kBranchReturnOffset = 2 * Instruction::kInstrSize; 789 const int kBranchReturnOffset = 2 * Instruction::kInstrSize;
781 790
782 const int kDoubleAlignmentBits = 3; 791 const int kDoubleAlignmentBits = 3;
783 const int kDoubleAlignment = (1 << kDoubleAlignmentBits); 792 const int kDoubleAlignment = (1 << kDoubleAlignmentBits);
784 const int kDoubleAlignmentMask = kDoubleAlignment - 1; 793 const int kDoubleAlignmentMask = kDoubleAlignment - 1;
785 794
786 795
787 } } // namespace v8::internal 796 } } // namespace v8::internal
788 797
789 #endif // #ifndef V8_MIPS_CONSTANTS_H_ 798 #endif // #ifndef V8_MIPS_CONSTANTS_H_
OLDNEW
« no previous file with comments | « src/mips/code-stubs-mips.cc ('k') | src/mips/disasm-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698