Index: src/compiler/s390/code-generator-s390.cc |
diff --git a/src/compiler/s390/code-generator-s390.cc b/src/compiler/s390/code-generator-s390.cc |
index 3ebe0827482bd7bc6055c2bb7cde94cbe8dbb68a..4837d38df0e980457551900b6f390a079772377c 100644 |
--- a/src/compiler/s390/code-generator-s390.cc |
+++ b/src/compiler/s390/code-generator-s390.cc |
@@ -67,8 +67,8 @@ class S390OperandConverter final : public InstructionOperandConverter { |
MemOperand MemoryOperand(AddressingMode* mode, size_t* first_index) { |
const size_t index = *first_index; |
- *mode = AddressingModeField::decode(instr_->opcode()); |
- switch (*mode) { |
+ if (mode) *mode = AddressingModeField::decode(instr_->opcode()); |
+ switch (AddressingModeField::decode(instr_->opcode())) { |
case kMode_None: |
break; |
case kMode_MRI: |
@@ -82,7 +82,8 @@ class S390OperandConverter final : public InstructionOperandConverter { |
return MemOperand(r0); |
} |
- MemOperand MemoryOperand(AddressingMode* mode, size_t first_index = 0) { |
+ MemOperand MemoryOperand(AddressingMode* mode = NULL, |
+ size_t first_index = 0) { |
return MemoryOperand(mode, &first_index); |
} |
@@ -1660,6 +1661,21 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { |
case kCheckedStoreFloat64: |
ASSEMBLE_CHECKED_STORE_DOUBLE(); |
break; |
+ case kAtomicLoadInt8: |
+ __ LoadB(i.OutputRegister(), i.MemoryOperand()); |
+ break; |
+ case kAtomicLoadUint8: |
+ __ LoadlB(i.OutputRegister(), i.MemoryOperand()); |
+ break; |
+ case kAtomicLoadInt16: |
+ __ LoadHalfWordP(i.OutputRegister(), i.MemoryOperand()); |
+ break; |
+ case kAtomicLoadUint16: |
+ __ LoadLogicalHalfWordP(i.OutputRegister(), i.MemoryOperand()); |
+ break; |
+ case kAtomicLoadWord32: |
+ __ Load(i.OutputRegister(), i.MemoryOperand()); |
+ break; |
default: |
UNREACHABLE(); |
break; |