[llvm] r314179 - [AVR] Use 1-byte alignment for all data types
Dylan McKay via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 25 17:45:27 PDT 2017
Author: dylanmckay
Date: Mon Sep 25 17:45:27 2017
New Revision: 314179
URL: http://llvm.org/viewvc/llvm-project?rev=314179&view=rev
Log:
[AVR] Use 1-byte alignment for all data types
This was an oversight in the original backend data layout.
The AVR architecture does not have the concept of unaligned loads - all
loads/stores from all addresses are aligned to one byte.
Discovered in avr-rust issue #64
https://github.com/avr-rust/rust/issues/64
Patch By Gergo Erdi.
Modified:
llvm/trunk/lib/Target/AVR/AVRTargetMachine.cpp
Modified: llvm/trunk/lib/Target/AVR/AVRTargetMachine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AVR/AVRTargetMachine.cpp?rev=314179&r1=314178&r2=314179&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AVR/AVRTargetMachine.cpp (original)
+++ llvm/trunk/lib/Target/AVR/AVRTargetMachine.cpp Mon Sep 25 17:45:27 2017
@@ -25,7 +25,7 @@
namespace llvm {
-static const char *AVRDataLayout = "e-p:16:16:16-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-n8";
+static const char *AVRDataLayout = "e-p: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) {
More information about the llvm-commits
mailing list