mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-19 08:31:11 +00:00
Temporarily avoid use of Writeable.
This commit is contained in:
parent
009915f4de
commit
797c9fe129
@ -46,7 +46,8 @@ class Writeable {
|
||||
private:
|
||||
IntT &target_;
|
||||
};
|
||||
template <typename IntT> struct ReturnType<IntT, AccessType::Write> { using type = Writeable<IntT>; };
|
||||
//template <typename IntT> struct ReturnType<IntT, AccessType::Write> { using type = Writeable<IntT>; };
|
||||
template <typename IntT> struct ReturnType<IntT, AccessType::Write> { using type = IntT &; };
|
||||
|
||||
// Read-modify-writes: return a reference.
|
||||
template <typename IntT> struct ReturnType<IntT, AccessType::ReadModifyWrite> { using type = IntT &; };
|
||||
|
@ -273,7 +273,7 @@ struct Memory {
|
||||
// Entry point used by the flow controller so that it can mark up locations at which the flags were written,
|
||||
// so that defined-flag-only masks can be applied while verifying RAM contents.
|
||||
template <typename IntT, AccessType type>
|
||||
typename ReturnType<IntT, type>::type &access(InstructionSet::x86::Source segment, uint16_t offset, Tag tag) {
|
||||
typename InstructionSet::x86::ReturnType<IntT, type>::type &access(InstructionSet::x86::Source segment, uint16_t offset, Tag tag) {
|
||||
const uint32_t physical_address = address(segment, offset);
|
||||
return access<IntT, type>(physical_address, tag);
|
||||
}
|
||||
@ -281,7 +281,7 @@ struct Memory {
|
||||
// An additional entry point for the flow controller; on the original 8086 interrupt vectors aren't relative
|
||||
// to a selector, they're just at an absolute location.
|
||||
template <typename IntT, AccessType type>
|
||||
typename ReturnType<IntT, type>::type &access(uint32_t address, Tag tag) {
|
||||
typename InstructionSet::x86::ReturnType<IntT, type>::type &access(uint32_t address, Tag tag) {
|
||||
if constexpr (type == AccessType::PreauthorisedRead) {
|
||||
if(!test_preauthorisation(address)) {
|
||||
printf("Non preauthorised access\n");
|
||||
|
Loading…
Reference in New Issue
Block a user