Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion clang/lib/Basic/Targets/AVR.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ class LLVM_LIBRARY_VISIBILITY AVRTargetInfo : public TargetInfo {
Int16Type = SignedInt;
Char32Type = UnsignedLong;
SigAtomicType = SignedChar;
resetDataLayout("e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8");
resetDataLayout(
"e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8");
}

void getTargetDefines(const LangOptions &Opts,
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Target/AVR/AVRTargetMachine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
namespace llvm {

static const char *AVRDataLayout =
"e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8";
"e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8";

/// Processes a CPU name.
static StringRef getCPU(StringRef CPU) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/AVR/block-address-is-in-progmem-space.ll
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
; This would cause a load of uninitialized memory, not even
; touching the program's machine code as otherwise desired.

target datalayout = "e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target datalayout = "e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"

; CHECK-LABEL: load_with_no_forward_reference
define i8 @load_with_no_forward_reference(i8 %a, i8 %b) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/test/CodeGen/AVR/shift-expand.ll
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
; amount to a loop. These loops avoid generating a (non-existing) builtin such
; as __ashlsi3.

target datalayout = "e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target datalayout = "e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target triple = "avr"

define i16 @shl16(i16 %value, i16 %amount) addrspace(1) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
; ArgumentPromotion should preserve the default function address space
; from the data layout.

target datalayout = "e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target datalayout = "e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"

@g = common global i32 0, align 4

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
; ArgumentPromotion should preserve the default function address space
; from the data layout.

target datalayout = "e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target datalayout = "e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"

@g = common global i32 0, align 4

Expand Down
2 changes: 1 addition & 1 deletion llvm/test/Transforms/DeadArgElim/nonzero-address-spaces.ll
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
; DeadArgumentElimination should respect the function address space
; in the data layout.

target datalayout = "e-P1-p:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"
target datalayout = "e-P1-p0:16:8-p1:16:8-i8:8-i16:8-i32:8-i64:8-f32:8-f64:8-n8-a:8"

; CHECK: define internal i32 @foo() addrspace(1)
define internal i32 @foo(i32 %x) #0 {
Expand Down