This paper presents a configurable assembler framework enhanced with reinforcement learning (RL) and MARTE (Modeling and Analysis of Real-Time and Embedded Systems) constraints to address the challenges of rapidly evolving processor architectures. Our methodology integrates formal hardware/software modeling with self-optimizing configuration strategies, enabling automatic adaptation to instruction set architecture (ISA) modifications while ensuring correctness guarantees. The framework features a Common ISA Description Language (CIDL) interface that reduces code modification efforts by 85% compared to traditional assemblers, as demonstrated through four representative configuration scenarios. By formulating the adaptation process as a constrained Markov Decision Process, our RL-MARTE hybrid approach achieves 58% fewer configuration steps and 26.5% higher code density, i.e., the ratio of useful instruction bytes to total code size, than rule-based methods, while maintaining zero constraint violations. Experimental results on the TOP-32A processor extension demonstrate the solution’s effectiveness in handling complex ISA modifications like MIMD instructions, reducing average configuration time from 45.6 to 9.8 minutes per task. This work bridges the gap between formal verification and practical adaptability in compiler construction, offering a systematic approach for next-generation processor toolchain development.
Hu, W., Zhang, F. and Li, Z. (2005) Microarchitecture of the Godson-2 Processor. JournalofComputerScienceandTechnology, 20, 243-249. https://doi.org/10.1007/s11390-005-0243-6
[4]
Leibson, S. and Kim, J. (2005) Configurable Processors: A New Era in Chip Design. Computer, 38, 51-59. https://doi.org/10.1109/mc.2005.226
Hadjiyiannis, G., Hanono, S. and Devadas, S. (1997) ISDL: An Instruction Set Description Language for Retargetability. Proceedingsofthe 34th Annual Conference onDesign Automation Conference-DAC ‘97, Anaheim, 9-13 June 1997, 299-302. https://doi.org/10.1145/266021.266108
[9]
Xiao, X. and Liu, Z. (2023) ISADL: An Instruction Set Architecture Description Language for VLIW. 2023 IEEE 29thInternationalConferenceonParallelandDistributedSystems (ICPADS), Ocean Flower Island, 17-21 December 2023, 92-99. https://doi.org/10.1109/icpads60453.2023.00022
[10]
Xiao, X. and Liu, Z. (2024) An Adaptive Instruction Set Encoding Automatic Generation Method for VLIW. In: Tari, Z., Li, K.Q. and Wu, H.Y., Eds., Algorithms and Architectures for Parallel Processing, Springer, 283-300. https://doi.org/10.1007/978-981-97-0834-5_17
[11]
Himmelbauer, S., Hochrainer, C., Huber, B., Mischkulnig, N., et al. (2024) The Vienna Architecture Description Language.
[12]
Chen, W., Ray, S., Bhadra, J., Abadir, M. and Wang, L. (2017) Challenges and Trends in Modern Soc Design Verification. IEEEDesign&Test, 34, 7-22. https://doi.org/10.1109/mdat.2017.2735383
[13]
Arbone, C., Ditu, B., Craciun, S. and Badea, D. (2013) Model-Driven Inline Assembler Generator for Retargetable Compilers. 2013 19thInternationalConferenceonControlSystemsandComputerScience, Bucharest, 29-31 May 2013, 71-76. https://doi.org/10.1109/cscs.2013.37
[14]
Povazan, I., Popovic, M., Djukic, M. and Cetic, N. (2013) A Retargetable C Compiler for Embedded Systems. 2013 3rdEasternEuropeanRegionalConferenceontheEngineeringofComputerBasedSystems, Budapest, 29-30 August 2013, 48-54. https://doi.org/10.1109/ecbs-eerc.2013.15
[15]
Korenkov, I., Loginov, I., Doronin, O., Sadyrin, D. and Derga-chev, A. (2019) Retargetable Compiler Design Issues. International Multidisciplinary Scientific GeoConference: SGEM, 19, 561-568.
[16]
Vasilache, N., Zinenko, O., Bik, A.J.C., etal. (2022) Composable and Modular Code Generation in MLIR: A Structured and Retargetable Approach to Tensor Compiler Construction.
[17]
Taglietti, L., Filho, J.O.C., Casarotto, D.C., Furtado, O.J.V. and dos Santos, L.C.V. (2005) Automatically Retargetable Pre-Processor and Assembler Generation for ASIPS. The 3rdInternationalIEEE-NEWCASConference, Quebec, 19-22 June 2005, 215-218.
[18]
Abbaspour, M. and Zhu, J. (2002) Retargetable Binary Utilities. Proceedingsofthe 39th Conference onDesign AutomationDAC ‘02, New Orleans, 10-14 June 2002, 331-336. https://doi.org/10.1145/513918.514004
[19]
Youn, J., Kim, H., Ahn, M., et al. (2008) Binutils Retargetable Assembler Linker. Proceedingsofthe 30thKoreanInformationProcessingSocietyAutumnConference, Vol. 15, 843-845.
[20]
Baldassin, A., Centoducatte, P. and Santos, L. (2011) Retargetable Binary Tools. In: Rigo, S., Azevedo, R. and Santos, L., Eds., ElectronicSystemLevelDesign, Springer, 99-114. https://doi.org/10.1007/978-1-4020-9940-3_6
[21]
Moona, R. (2000) Processor Models for Retargetable Tools. Proceedings 11thInternationalWorkshoponRapidSystemPrototyping. RSP 2000. ShorteningthePathfromSpecificationtoPrototype (Cat. No.PR00668), Paris, 21-23 June 2000, 34-39. https://doi.org/10.1109/iwrsp.2000.855183
[22]
Hu, M., Zhang, M., Mallet, F., Fu, X. and Chen, M. (2023) Accelerating Reinforcement Learning-Based CCSL Specification Synthesis Using Curiosity-Driven Exploration. IEEETransactionsonComputers, 72, 1431-1446. https://doi.org/10.1109/tc.2022.3197956