Simon Wallis 94e4e37d55 [Thumb] set code alignment for 16-bit load from constant pool
Summary:
[Thumb] set code alignment for 16-bit load from constant pool

LLVM miscompiles this code when compiling for a target with v8.2-A FP16 and the Thumb ISA at -O0:

extern void bar(__fp16 P5);

int main() {
  __fp16 P5 = 1.96875;
  bar(P5);
}

The code section containing main has 2 byte alignment.
It needs to have 4 byte alignment,
because the load literal instruction has an offset from the
load address with the low 2 bits zeroed.

I do not include a test case in this check-in.
llc and llvm-mc do not exhibit this bug. They do not set code section alignment
in the same manner as clang.

Reviewers: dnsampaio

Reviewed By: dnsampaio

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D84169
2020-07-22 10:12:41 +01:00
..
2019-05-15 12:41:58 +00:00
2020-01-07 16:51:11 +00:00
2020-06-18 17:26:24 +01:00
2019-08-01 11:12:10 +00:00
2020-02-24 14:19:21 +00:00
2020-05-14 16:46:16 +01:00
2018-10-14 16:49:04 +00:00
2020-07-16 11:25:53 +01:00
2020-07-16 11:25:53 +01:00
2018-07-04 13:28:39 +00:00
2019-10-08 08:25:42 +00:00
2020-04-09 10:36:00 +01:00
2019-01-07 12:21:13 +00:00
2019-02-26 12:02:12 +00:00
2019-12-12 13:51:39 +00:00
2019-06-11 11:09:25 +00:00
2018-09-26 10:56:00 +00:00
2020-03-31 10:11:36 +01:00
2019-04-17 16:51:09 +00:00
2019-10-08 16:16:26 +00:00
2019-07-29 09:48:07 +00:00
2020-02-20 13:54:43 +00:00
2020-01-21 10:40:17 +00:00
2019-07-27 18:44:15 +00:00
2020-07-16 11:25:53 +01:00
2019-10-08 08:25:42 +00:00
2019-11-04 13:37:01 +00:00
2019-10-08 08:25:42 +00:00
2020-07-16 11:25:53 +01:00