Isaac Richter fa1145a8d2 [lld][ELF] Add LOG2CEIL builtin ldscript function
This patch adds support for the LOG2CEIL builtin function in linker scripts: https://sourceware.org/binutils/docs/ld/Builtin-Functions.html#index-LOG2CEIL_0028exp_0029

As documented for LD, and to keep compatibility, LOG2CEIL(0) returns 0 (not -inf).

The test vectors are somewhat arbitrary. We check minimum values (0-4); middle values (2^32, and 2^32+1); and the maximum value (2^64-1).

The checks for LOG2CEIL explicitly use full 64-bit values (16 hex digits). This is needed to properly verify that -inf and other interesting results aren't returned. (For some reason, all other tests in operators.test use only 14 digits.)

Differential revision: https://reviews.llvm.org/D84054
2020-07-27 12:16:43 +03:00
..
2018-07-05 16:03:20 +00:00
2020-06-01 10:19:41 -07:00
2019-07-22 11:37:03 +00:00
2020-03-27 11:56:02 -07:00
2018-04-09 12:45:29 +00:00
2020-03-27 11:56:02 -07:00
2020-03-31 12:41:18 +01:00
2020-07-23 08:16:01 -07:00
2019-09-07 10:42:11 +00:00
2019-09-07 10:42:11 +00:00
2020-03-27 11:56:02 -07:00
2020-04-13 19:32:44 -05:00
2019-08-01 09:25:34 +00:00
2020-05-29 14:22:03 -07:00
2018-08-08 14:50:33 +00:00
2018-08-08 14:50:33 +00:00
2018-08-08 14:50:33 +00:00
2018-03-27 16:10:01 +00:00
2019-09-07 10:42:11 +00:00
2020-06-01 10:19:41 -07:00
2019-07-25 07:12:23 +00:00
2019-09-07 10:42:11 +00:00
2020-06-01 10:19:41 -07:00
2020-06-01 10:19:41 -07:00
2019-09-07 10:42:11 +00:00
2020-06-01 10:19:41 -07:00
2019-02-06 01:00:49 +00:00
2018-04-24 23:03:58 +00:00
2019-09-07 10:42:11 +00:00