Andreas Schwab
1b183017aa
Add basic support for RISC-V 64-bit EFI objects
This adds a new PEI target pei-riscv64-little. Only objdump and objcopy
are supported.
bfd:
* .gitignore: Add pe-riscv64igen.c.
* Makefile.am (BFD64_BACKENDS): Add pei-riscv64.lo,
pe-riscv64igen.lo.
(BFD64_BACKENDS_CFILES): Add pei-riscv64.c.
(BUILD_CFILES): Add pe-riscv64igen.c.
(pe-riscv64igen.c): New rule.
* Makefile.in: Regenerate.
* bfd.c (bfd_get_sign_extend_vma): Add pei-riscv64-little.
* coff-riscv64.c: New file.
* coffcode.h (coff_set_arch_mach_hook, coff_set_flags)
(coff_write_object_contents): Add riscv64 (riscv64_pei_vec)
support.
* config.bfd (targ_selvecs): Add riscv64_pei_vec to all riscv*
targets.
* configure.ac: Handle riscv64_pei_vec.
* configure: Regenerate.
* libpei.h (GET_OPTHDR_IMAGE_BASE, PUT_OPTHDR_IMAGE_BASE)
(GET_OPTHDR_SIZE_OF_STACK_RESERVE)
(PUT_OPTHDR_SIZE_OF_STACK_RESERVE)
(GET_OPTHDR_SIZE_OF_STACK_COMMIT, PUT_OPTHDR_SIZE_OF_STACK_COMMIT)
(GET_OPTHDR_SIZE_OF_HEAP_RESERVE, PUT_OPTHDR_SIZE_OF_HEAP_RESERVE)
(GET_OPTHDR_SIZE_OF_HEAP_COMMIT, PUT_OPTHDR_SIZE_OF_HEAP_COMMIT)
(GET_PDATA_ENTRY, _bfd_XX_bfd_copy_private_bfd_data_common)
(_bfd_XX_bfd_copy_private_section_data)
(_bfd_XX_get_symbol_info, _bfd_XX_only_swap_filehdr_out)
(_bfd_XX_print_private_bfd_data_common)
(_bfd_XXi_final_link_postscript, _bfd_XXi_only_swap_filehdr_out)
(_bfd_XXi_swap_aouthdr_in, _bfd_XXi_swap_aouthdr_out)
(_bfd_XXi_swap_aux_in, _bfd_XXi_swap_aux_out)
(_bfd_XXi_swap_lineno_in, _bfd_XXi_swap_lineno_out)
(_bfd_XXi_swap_scnhdr_out, _bfd_XXi_swap_sym_in)
(_bfd_XXi_swap_sym_out, _bfd_XXi_swap_debugdir_in)
(_bfd_XXi_swap_debugdir_out, _bfd_XXi_write_codeview_record)
(_bfd_XXi_slurp_codeview_record) [COFF_WITH_peRiscV64]: Define.
(_bfd_peRiscV64_print_ce_compressed_pdata): Declare.
* peXXigen.c (_bfd_XXi_swap_aouthdr_in, _bfd_XXi_swap_aouthdr_out)
(_bfd_XXi_swap_scnhdr_out, pe_print_pdata)
(_bfd_XX_print_private_bfd_data_common)
(_bfd_XX_bfd_copy_private_section_data)
(_bfd_XXi_final_link_postscript): Support COFF_WITH_peRiscV64.
* pei-riscv64.c: New file.
* peicode.h (coff_swap_scnhdr_in, pe_ILF_build_a_bfd)
(pe_ILF_object_p): Support COFF_WITH_peRiscV64.
(jtab): Add dummy entry that traps.
* targets.c (_bfd_target_vector): Add riscv64_pei_vec.
binutils:
* testsuite/binutils-all/riscv/pei-riscv64.d: New.
* testsuite/binutils-all/riscv/pei-riscv64.s: New.
include:
* coff/riscv64.h: New file.
* coff/pe.h (IMAGE_FILE_MACHINE_RISCV32)
(IMAGE_FILE_MACHINE_RISCV64): Define.
2023-12-05 13:20:27 +01:00
..
2023-01-01 21:50:11 +10:30
2023-09-25 10:32:52 +03:00
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-08-22 09:35:55 +09:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-11-13 15:58:03 +00:00
2023-01-01 21:50:11 +10:30
2023-12-05 13:20:27 +01:00
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-07-09 10:57:19 -07:00
2023-10-05 14:49:51 +01:00
2023-09-26 16:27:28 +01:00
2023-01-01 21:50:11 +10:30
2020-07-07 18:26:33 +09:30
2020-07-07 18:26:33 +09:30
2020-07-07 18:26:33 +09:30
2023-01-01 21:50:11 +10:30
2023-04-26 10:32:07 +09:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2022-08-13 14:11:27 +09:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2023-08-22 09:35:55 +09:30
2023-01-01 21:50:11 +10:30
2022-08-13 14:11:27 +09:30
2020-03-19 16:55:13 +00:00
2023-01-01 21:50:11 +10:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2023-03-14 12:21:13 +00:00
2023-01-01 21:50:11 +10:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2020-06-30 08:56:14 -07:00
2021-11-17 05:15:48 -08:00
2023-01-01 21:50:11 +10:30
2020-11-20 14:06:14 +00:00
2019-11-04 11:55:28 +10:30
2019-11-04 11:55:28 +10:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2020-08-14 21:29:57 +09:30
2023-08-16 14:22:54 +01:00
2022-05-18 13:15:22 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2019-10-25 16:46:07 +01:00
2023-08-16 14:22:54 +01:00
2023-11-14 10:57:58 +00:00
2023-11-14 10:57:58 +00:00
2022-08-13 14:11:27 +09:30
2022-05-20 16:55:36 +01:00
2022-08-13 14:11:27 +09:30
2021-03-04 10:41:22 +00:00
2023-03-14 12:21:13 +00:00
2023-11-14 10:57:58 +00:00
2020-03-02 10:02:02 +00:00
2020-03-02 10:02:02 +00:00
2020-06-04 23:41:57 -07:00
2020-03-27 10:54:26 +00:00
2021-02-12 18:55:36 +10:30
2020-06-23 06:52:41 -07:00
2022-08-13 14:11:27 +09:30
2020-06-23 09:20:28 -07:00
2022-11-04 16:47:43 -07:00
2021-02-17 16:57:59 +10:30
2021-02-17 16:57:59 +10:30
2021-02-17 16:57:59 +10:30
2020-11-20 10:33:28 +00:00
2020-11-20 10:33:28 +00:00
2020-11-20 10:33:28 +00:00
2020-11-18 11:51:13 +00:00
2020-08-12 13:31:59 +01:00
2023-05-30 19:56:45 +08:00
2022-08-13 14:11:27 +09:30
2022-08-13 14:11:27 +09:30
2022-05-20 16:55:36 +01:00
2020-11-13 16:02:39 +00:00
2023-07-28 06:00:36 +01:00
2021-07-13 14:07:57 +08:00
2023-06-15 04:45:03 +01:00
2023-10-03 12:41:02 +01:00
2021-08-30 17:36:11 +08:00
2021-08-30 17:36:11 +08:00
2021-08-30 17:36:11 +08:00
2021-08-30 17:36:11 +08:00
2021-04-21 10:34:32 +01:00
2021-08-30 17:36:11 +08:00
2022-08-13 14:11:27 +09:30
2022-08-13 14:11:27 +09:30
2023-07-28 06:00:37 +01:00
2023-07-28 06:00:37 +01:00
2023-07-28 06:00:37 +01:00
2023-07-28 06:00:37 +01:00
2022-11-14 13:40:52 +10:30
2020-11-18 11:51:13 +00:00
2021-02-02 05:15:05 -08:00
2020-11-18 11:51:13 +00:00
2020-07-07 18:26:33 +09:30
2023-01-01 21:50:11 +10:30
2023-01-01 21:50:11 +10:30
2023-07-28 06:00:36 +01:00
2023-06-29 10:29:47 -07:00
2022-08-13 14:11:27 +09:30
2022-08-13 14:11:27 +09:30
2023-01-01 21:50:11 +10:30
2022-12-01 13:09:26 +00:00
2022-03-16 09:40:13 -07:00
2020-04-29 16:01:40 +01:00
2020-04-29 16:01:40 +01:00