require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_AARCH64_ASM_H_)) {
    eval 'sub _AARCH64_ASM_H_ () {1;}' unless defined(&_AARCH64_ASM_H_);
    if(defined(&_KERNEL_OPT)) {
	require './aarch64/opt_cpuoptions.ph';
    }
    require 'arm/asm.ph';
    if(defined(&__aarch64__)) {
	if(defined(&__ASSEMBLER__)) {
	}
	eval 'sub fp () { &x29;}' unless defined(&fp);
	eval 'sub lr () { &x30;}' unless defined(&lr);
	eval 'sub ERET () { &eret;  &dsb  &sy;  &isb;}' unless defined(&ERET);
	if(defined(&ARMV83_PAC)) {
	    eval 'sub ARMV8_DEFINE_OPTIONS () {. &arch  &armv8.3- &a;}' unless defined(&ARMV8_DEFINE_OPTIONS);
	}
 elsif(defined(&ARMV81_PAN)) {
	    eval 'sub ARMV8_DEFINE_OPTIONS () {. &arch  &armv8.1- &a;}' unless defined(&ARMV8_DEFINE_OPTIONS);
	} else {
	    eval 'sub ARMV8_DEFINE_OPTIONS () {1;}' unless defined(&ARMV8_DEFINE_OPTIONS);
	}
    }
}
1;
