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

Side by Side Diff: src/memory.h

Issue 115816: Add immediate operands and arithmetic operations to the x64 assembler. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 7 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 | « no previous file | src/x64/assembler-x64.h » ('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 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 26 matching lines...) Expand all
37 class Memory { 37 class Memory {
38 public: 38 public:
39 static uint32_t& uint32_at(Address addr) { 39 static uint32_t& uint32_at(Address addr) {
40 return *reinterpret_cast<uint32_t*>(addr); 40 return *reinterpret_cast<uint32_t*>(addr);
41 } 41 }
42 42
43 static int32_t& int32_at(Address addr) { 43 static int32_t& int32_at(Address addr) {
44 return *reinterpret_cast<int32_t*>(addr); 44 return *reinterpret_cast<int32_t*>(addr);
45 } 45 }
46 46
47 static uint64_t& uint64_at(Address addr) {
48 return *reinterpret_cast<uint64_t*>(addr);
49 }
50
47 static int& int_at(Address addr) { 51 static int& int_at(Address addr) {
48 return *reinterpret_cast<int*>(addr); 52 return *reinterpret_cast<int*>(addr);
49 } 53 }
50 54
51 static Address& Address_at(Address addr) { 55 static Address& Address_at(Address addr) {
52 return *reinterpret_cast<Address*>(addr); 56 return *reinterpret_cast<Address*>(addr);
53 } 57 }
54 58
55 static Object*& Object_at(Address addr) { 59 static Object*& Object_at(Address addr) {
56 return *reinterpret_cast<Object**>(addr); 60 return *reinterpret_cast<Object**>(addr);
57 } 61 }
58 }; 62 };
59 63
60 } } // namespace v8::internal 64 } } // namespace v8::internal
61 65
62 #endif // V8_MEMORY_H_ 66 #endif // V8_MEMORY_H_
OLDNEW
« no previous file with comments | « no previous file | src/x64/assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698