diff options
author | Alan Modra <amodra@gmail.com> | 2023-03-09 11:53:16 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2023-03-10 21:22:16 +1030 |
commit | 75bd292bea53d6ce8de66f30d67c2edb4a558110 (patch) | |
tree | 82b642338ab4ecb6404ea72442d4d40e5a3cb64b /ld/ldgram.y | |
parent | 36ba37c085438d23de2289ea17b56e7b91d1c5c5 (diff) | |
download | gdb-75bd292bea53d6ce8de66f30d67c2edb4a558110.zip gdb-75bd292bea53d6ce8de66f30d67c2edb4a558110.tar.gz gdb-75bd292bea53d6ce8de66f30d67c2edb4a558110.tar.bz2 |
Revert ld DIGEST support
This is a hopefully temporary reversion of new ld features for
embedded processors by Ulf Samuelsson, plus some followup patches.
Squashed together from the following:
Revert "lddigest 32-bit support and gcc-4 compile errors"
This reverts commit d7ee19be87110a8f5342cec6e323d83d01c641d1.
Revert "ld: Use correct types for crc64 calculations"
This reverts commit 9a534b9f8e3d0f3cdb5a20f19ff165693fbb84d2.
Revert "Re: DIGEST: testsuite"
This reverts commit c8e85484d8a0fe9f7b88e00a6b9ae63bcb53ba32.
Revert "Regen potfiles"
This reverts commit 4d98c966f8bf305ab25badd34cb295631873cf7c.
Revert "DIGEST: Makefile.*"
This reverts commit 78ef6ab03f56ce83a606d974bb8a9f34b5d6e0b7.
Revert "DIGEST: calculation"
This reverts commit 5243990191e683d5066d3dd622c76deaba0bf15c.
Revert "DIGEST: ldlang.*: add timestamp"
This reverts commit bd9466d4aa277a469a9d8b12f0a6e6fa51678e36.
Revert "DIGEST: ldmain.c"
This reverts commit c8f8653fa7eeb3dc0769ac23039eadb5c5f09dff.
Revert "DIGEST: ldgram.y"
This reverts commit d73c01be2669e9c5267fab669a269f95a32048c9.
Revert "DIGEST: ldlex.l"
This reverts commit 48b5163a9dd5759cc87171331bbd6e902c547b5a.
Revert "DIGEST: testsuite"
This reverts commit a4135d1a4886400ea29af2da782dd8dd40ccad23.
Revert "DIGEST: Documentation"
This reverts commit 3ec28966c3e4c63704212778f96c517cbf2e0090.
Revert "DIGEST: NEWS"
This reverts commit 099bf2927d446424e8585a60cf4ce63209999aa2.
Revert "DIGEST: LICENSING"
This reverts commit 5c8a0c6654fb55926985edf3b360b62d4f20691d.
Diffstat (limited to 'ld/ldgram.y')
-rw-r--r-- | ld/ldgram.y | 61 |
1 files changed, 1 insertions, 60 deletions
diff --git a/ld/ldgram.y b/ld/ldgram.y index 93aff6e..26e56fe 100644 --- a/ld/ldgram.y +++ b/ld/ldgram.y @@ -41,7 +41,6 @@ #include "mri.h" #include "ldctor.h" #include "ldlex.h" -#include "lddigest.h" #ifndef YYDEBUG #define YYDEBUG 1 @@ -131,9 +130,6 @@ static int error_index; %token DATA_SEGMENT_ALIGN DATA_SEGMENT_RELRO_END DATA_SEGMENT_END %token SORT_BY_NAME SORT_BY_ALIGNMENT SORT_NONE %token SORT_BY_INIT_PRIORITY -%token DIGEST POLY POLYI TABLE -%token TIMESTAMP -%token DEBUG ON OFF %token '{' '}' %token SIZEOF_HEADERS OUTPUT_FORMAT FORCE_COMMON_ALLOCATION OUTPUT_ARCH %token INHIBIT_COMMON_ALLOCATION FORCE_GROUP_ALLOCATION @@ -672,7 +668,7 @@ statement: { lang_add_data ((int) $1, $3); } - | ASCII '(' mustbe_exp ')' NAME + | ASCII '(' mustbe_exp ')' NAME { /* 'value' is a memory leak, do we care? */ etree_type *value = $3; @@ -689,31 +685,6 @@ statement: { lang_add_fill ($3); } - | DIGEST NAME - { /* CRC_ADDRESS is set in <polynome>, but polynome reserves space, so we use a temporary */ - digest_label = lang_get_label ($2, &digest_big_endian); - lang_add_assignment (exp_assign (digest_label, exp_nameop (NAME, "."), false)); - } - polynome '(' mustbe_exp ',' mustbe_exp ')' - { - if (polynome_valid) - { - lang_add_assignment (exp_assign (CRC_ADDRESS, exp_nameop (NAME, digest_label), false)); - lang_add_assignment (exp_assign (CRC_START, $6, false)); - lang_add_assignment (exp_assign (CRC_END, $8, false)); - } - } - | DIGEST TABLE NAME - { - bool big_endian; - const char *label = lang_get_label($3, &big_endian); - lang_add_assignment (exp_assign (label, exp_nameop (NAME,"."), false)); - lang_add_digest_table (big_endian); - } - | TIMESTAMP - { - lang_add_timestamp (); - } | ASSERT_K { ldlex_expression (); } '(' exp ',' NAME ')' separator @@ -721,43 +692,13 @@ statement: ldlex_popstate (); lang_add_assignment (exp_assert ($4, $6)); } - | DEBUG ON - { - yydebug = 1; - } - | DEBUG OFF - { - yydebug = 0; - } | INCLUDE filename { ldfile_open_command_file ($2); } - statement_list_opt END ; -polynome: - NAME - { - polynome_valid = lang_set_digest ($1); - } - | POLY '(' mustbe_exp ',' - mustbe_exp ',' mustbe_exp ',' mustbe_exp ',' - mustbe_exp ',' mustbe_exp ',' mustbe_exp ')' - { - lang_add_digest ( - $3, /* size */ - $5, /* polynome */ - $7, /* initial value */ - $9, /* xor value */ - $11, /* input reflected */ - $13, /* output reflected */ - $15 /* reciprocal */ - ); - polynome_valid = true; - } - statement_list: statement_list statement | statement |