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

Side by Side Diff: src/compiler/s390/code-generator-s390.cc

Issue 2071883002: S390: [wasm] Relocatable Globals. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 6 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
« no previous file with comments | « no previous file | src/s390/assembler-s390.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/code-generator.h" 5 #include "src/compiler/code-generator.h"
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/compiler/code-generator-impl.h" 8 #include "src/compiler/code-generator-impl.h"
9 #include "src/compiler/gap-resolver.h" 9 #include "src/compiler/gap-resolver.h"
10 #include "src/compiler/node-matchers.h" 10 #include "src/compiler/node-matchers.h"
(...skipping 1979 matching lines...) Expand 10 before | Expand all | Expand 10 after
1990 Constant src = g.ToConstant(source); 1990 Constant src = g.ToConstant(source);
1991 if (destination->IsRegister() || destination->IsStackSlot()) { 1991 if (destination->IsRegister() || destination->IsStackSlot()) {
1992 Register dst = 1992 Register dst =
1993 destination->IsRegister() ? g.ToRegister(destination) : kScratchReg; 1993 destination->IsRegister() ? g.ToRegister(destination) : kScratchReg;
1994 switch (src.type()) { 1994 switch (src.type()) {
1995 case Constant::kInt32: 1995 case Constant::kInt32:
1996 #if V8_TARGET_ARCH_S390X 1996 #if V8_TARGET_ARCH_S390X
1997 if (src.rmode() == RelocInfo::WASM_MEMORY_SIZE_REFERENCE) { 1997 if (src.rmode() == RelocInfo::WASM_MEMORY_SIZE_REFERENCE) {
1998 #else 1998 #else
1999 if (src.rmode() == RelocInfo::WASM_MEMORY_REFERENCE || 1999 if (src.rmode() == RelocInfo::WASM_MEMORY_REFERENCE ||
2000 src.rmode() == RelocInfo::WASM_GLOBAL_REFERENCE ||
2000 src.rmode() == RelocInfo::WASM_MEMORY_SIZE_REFERENCE) { 2001 src.rmode() == RelocInfo::WASM_MEMORY_SIZE_REFERENCE) {
2001 #endif 2002 #endif
2002 __ mov(dst, Operand(src.ToInt32(), src.rmode())); 2003 __ mov(dst, Operand(src.ToInt32(), src.rmode()));
2003 } else { 2004 } else {
2004 __ mov(dst, Operand(src.ToInt32())); 2005 __ mov(dst, Operand(src.ToInt32()));
2005 } 2006 }
2006 break; 2007 break;
2007 case Constant::kInt64: 2008 case Constant::kInt64:
2008 #if V8_TARGET_ARCH_S390X 2009 #if V8_TARGET_ARCH_S390X
2009 if (src.rmode() == RelocInfo::WASM_MEMORY_REFERENCE) { 2010 if (src.rmode() == RelocInfo::WASM_MEMORY_REFERENCE ||
2011 src.rmode() == RelocInfo::WASM_GLOBAL_REFERENCE) {
2010 __ mov(dst, Operand(src.ToInt64(), src.rmode())); 2012 __ mov(dst, Operand(src.ToInt64(), src.rmode()));
2011 } else { 2013 } else {
2012 DCHECK(src.rmode() != RelocInfo::WASM_MEMORY_SIZE_REFERENCE); 2014 DCHECK(src.rmode() != RelocInfo::WASM_MEMORY_SIZE_REFERENCE);
2013 __ mov(dst, Operand(src.ToInt64())); 2015 __ mov(dst, Operand(src.ToInt64()));
2014 } 2016 }
2015 #else 2017 #else
2016 __ mov(dst, Operand(src.ToInt64())); 2018 __ mov(dst, Operand(src.ToInt64()));
2017 #endif // V8_TARGET_ARCH_S390X 2019 #endif // V8_TARGET_ARCH_S390X
2018 break; 2020 break;
2019 case Constant::kFloat32: 2021 case Constant::kFloat32:
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
2195 padding_size -= 2; 2197 padding_size -= 2;
2196 } 2198 }
2197 } 2199 }
2198 } 2200 }
2199 2201
2200 #undef __ 2202 #undef __
2201 2203
2202 } // namespace compiler 2204 } // namespace compiler
2203 } // namespace internal 2205 } // namespace internal
2204 } // namespace v8 2206 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/s390/assembler-s390.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698