2024-07-07 17:37:04 +02:00
|
|
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
|
//
|
|
|
|
|
// boot/w65c816s.h
|
2024-07-08 05:08:08 +02:00
|
|
|
|
// Defines for the 65C816 architecture
|
2024-07-07 17:37:04 +02:00
|
|
|
|
//
|
|
|
|
|
// Copyright © 2024 Kyle J Cardoza <Kyle.Cardoza@icloud.com>
|
|
|
|
|
|
2024-07-08 05:08:08 +02:00
|
|
|
|
#ifdef __CALYPSI_ASSEMBLER__
|
|
|
|
|
|
2024-07-07 17:37:04 +02:00
|
|
|
|
#define native_mode \
|
|
|
|
|
clc \
|
|
|
|
|
xce
|
|
|
|
|
|
|
|
|
|
#define long_a rep #0x20
|
|
|
|
|
|
|
|
|
|
#define short_a sep #0x20
|
|
|
|
|
|
|
|
|
|
#define long_i rep #0x10
|
|
|
|
|
|
|
|
|
|
#define short_i sep #0x10
|
|
|
|
|
|
|
|
|
|
#define save_registers \
|
|
|
|
|
php \
|
|
|
|
|
long_a \
|
|
|
|
|
long_i \
|
|
|
|
|
pha \
|
|
|
|
|
phx \
|
2024-07-08 02:50:53 +02:00
|
|
|
|
phy
|
2024-07-07 17:37:04 +02:00
|
|
|
|
|
|
|
|
|
#define restore_registers \
|
|
|
|
|
long_a \
|
|
|
|
|
long_i \
|
|
|
|
|
ply \
|
|
|
|
|
plx \
|
|
|
|
|
pla \
|
2024-07-08 02:50:53 +02:00
|
|
|
|
plp
|
2024-07-08 05:08:08 +02:00
|
|
|
|
|
|
|
|
|
#endif
|