name string | code string | asm string | file string |
|---|---|---|---|
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [18]>(char const (&) [18]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x77bb5(%rip... | /simonowen[P]samdisk/include/utils.h |
to_string[abi:cxx11](Range const&) | std::string to_string(const Range& range)
{
std::ostringstream ss;
auto separator = ", ";
if (range.empty())
return "All Tracks";
if (range.cyls() == 1)
ss << "Cyl " << CylStr(range.cyl_begin);
else if (range.cyl_begin == 0)
{
ss << std::setw(2) << range.cyl_end << " Cy... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x188, %rsp # imm = 0x188
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rsp), %rdi
callq 0x35760
movl (%r14), %eax
movl 0x4(%r14), %esi
movl %esi, %ecx
subl %eax, %ecx
jle 0x656b0
movl 0x8(%r14), %edx
cmpl %edx, 0xc(%r14)
jle 0x656b0
cmpl $0x1, %ecx
jne 0x656d2
... | /simonowen[P]samdisk/src/Range.cpp |
Range::each(std::function<void (CylHead const&)> const&, bool) const | void Range::each(const std::function<void(const CylHead & cylhead)>& func, bool cyls_first/*=false*/) const
{
if (cyls_first && heads() > 1)
{
for (auto head = head_begin; head < head_end; ++head)
for (auto cyl = cyl_begin; cyl < cyl_end; ++cyl)
func(CylHead(cyl, head));
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
testl %edx, %edx
je 0x65a07
movl 0x8(%r14), %ebp
movl 0xc(%r14), %eax
subl %ebp, %eax
cmpl $0x2, %eax
jl 0x65a07
cmpl 0xc(%r14), %ebp
jge 0x65a49
leaq 0x8(%rsp), %r15
movl (%r14), %r12d
cmpl 0x4(%r14), %r12d
jge 0x65... | /simonowen[P]samdisk/src/Range.cpp |
GetDiskInfo(unsigned char const*, MGT_DISK_INFO&) | MGT_DISK_INFO* GetDiskInfo(const uint8_t* p, MGT_DISK_INFO& di)
{
auto dir = reinterpret_cast<const MGT_DIR*>(p);
// Assume 4 directory tracks until we discover otherwise
di.dir_tracks = MGT_DIR_TRACKS;
// Determine the disk/DOS type, as each has different capabilities
if (!memcmp(dir->abBDOS, "BD... | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movl $0x4, 0x4(%rsi)
cmpl $0x534f4442, 0xe8(%rdi) # imm = 0x534F4442
je 0x65a95
movb 0xd2(%r14), %cl
decb %cl
xorl %eax, %eax
cmpb $-0x2, %cl
setb %al
jmp 0x65a9a
movl $0x2, %eax
movl %eax, (%rbx)
cmpl $0x2, %eax
je ... | /simonowen[P]samdisk/src/SAMCoupe.cpp |
SetDiskInfo(unsigned char, MGT_DISK_INFO&) | bool SetDiskInfo(uint8_t pb_, MGT_DISK_INFO& di)
{
auto p = reinterpret_cast<MGT_DIR*>(pb_);
auto modified = false;
// Extract the remaining disk information from type-specific locations
switch (di.dos_type)
{
case SamDosType::MasterDOS:
// Set serial number
p->extra.abSerial[0]... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movl %edi, %r15d
movl (%rsi), %eax
xorl %ebx, %ebx
testl %eax, %eax
je 0x65d30
cmpl $0x2, %eax
je 0x65d6d
cmpl $0x1, %eax
jne 0x65ed1
movb 0x29(%r14), %al
movb %al, 0xfc(%r15)
movb 0x28(%r14), %al
movb %al, 0xfd(%r15)
cmpq $0x0, 0x10(%r14)
je ... | /simonowen[P]samdisk/src/SAMCoupe.cpp |
GetFileTime(MGT_DIR const*, tm*) | bool GetFileTime(const MGT_DIR* p, struct tm* ptm_)
{
memset(ptm_, 0, sizeof(*ptm_));
// Check for a packed BDOS 1.4+ date
if (p->bMonth & 0x80)
{
ptm_->tm_sec = (p->bMinute & 0x1f) << 1;
ptm_->tm_min = ((p->bMinute & 0xe0) >> 2) | (p->bHour & 0x07);
ptm_->tm_hour = (p->bHour & ... | pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rsi)
movups %xmm0, 0x10(%rsi)
movups %xmm0, (%rsi)
movq $0x0, 0x30(%rsi)
movzbl 0xf6(%rdi), %eax
movzbl 0xf9(%rdi), %ecx
testb %al, %al
js 0x65f55
movl %ecx, 0x4(%rbx)
movzbl 0xf8(%rdi), %ecx
movl %ecx, 0x8(%rbx)
movzbl 0xf5(%rdi), %ecx
... | /simonowen[P]samdisk/src/SAMCoupe.cpp |
IsProDOSDisk(HDD const&, PRODOS_CAPS&) | bool IsProDOSDisk(const HDD& hdd, PRODOS_CAPS& pdc)
{
/*
Sector 0 - MS-DOS BOOT sector
Sector 1 - MS-DOS FAT
Sector 2 - MS-DOS ROOT directory
Sector 3 - Small "READ-ME.TXT" file visible to Windows/MS-DOS Etc.
Sector 4-67 - Pro-DOS system code (if the card was form... | cmpl $0x200, 0x18(%rdi) # imm = 0x200
jne 0x66088
movl $0x44, (%rsi)
movq 0x20(%rdi), %rax
leaq -0x44(%rax), %rcx
addq $0x7bb, %rax # imm = 0x7BB
testq %rcx, %rcx
cmovnsq %rcx, %rax
shrq $0xb, %rax
movl %eax, 0x4(%rsi)
movb $0x0, 0x8(%rsi)
leaq 0x49238(%rip), %rcx # 0xaf2ab
movl $0x1, %esi
movl $0x1... | /simonowen[P]samdisk/src/SAMCoupe.cpp |
IsBDOSDisk(HDD const&, BDOS_CAPS&) | bool IsBDOSDisk(const HDD& hdd, BDOS_CAPS& bdc)
{
bool f = false;
// Sector size must be 512 bytes for BDOS
if (hdd.sector_size != BDOS_SECTOR_SIZE)
return false;
MEMORY mem(hdd.sector_size);
// Determine BDOS parameters from the CHS geometry (as BDOS does)
GetBDOSCaps(hdd.cyls * hdd.... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r14
movl 0x18(%rdi), %edi
cmpl $0x200, %edi # imm = 0x200
jne 0x6611d
movq %rsi, %rbx
leaq 0x7636f(%rip), %rax # 0xdc420
leaq 0x10(%rsp), %r15
movq %rax, (%r15)
movl %edi, 0x8(%r15)
callq 0x77560
movq %rax, 0x1... | /simonowen[P]samdisk/src/SAMCoupe.cpp |
ReportBuildOptions() | void ReportBuildOptions()
{
static const std::vector<const char*> options{
#ifdef HAVE_ZLIB
"zlib",
#endif
#ifdef HAVE_BZIP2
"bzip2",
#endif
#ifdef HAVE_LZMA
"lzma",
#endif
#ifdef HAVE_WINUSB
"WinUSB",
#endif
#ifdef HAVE_LIBUSB1
"libusb1",
#endif
#ifdef HAVE_FTDI
"FTD... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movb 0x79233(%rip), %al # 0xdfce0
testb %al, %al
je 0x66b3a
movq 0x79214(%rip), %rax # 0xdfcd0
cmpq 0x79205(%rip), %rax # 0xdfcc8
je 0x66b2e
leaq 0x797e4(%rip), %rdi # 0xe02b0
leaq 0x48e32(%rip), %rsi # 0xaf905
callq 0x3fbbb
movq 0x791e9(... | /simonowen[P]samdisk/src/SAMdisk.cpp |
ParseCommandLine(int, char**) | bool ParseCommandLine(int argc_, char* argv_[])
{
int arg;
opterr = 1;
while ((arg = getopt_long(argc_, argv_, short_options, long_options, nullptr)) != -1)
{
switch (arg)
{
case 'c':
util::str_range(optarg, opt.range.cyl_begin, opt.range.cyl_end);
// -c... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x7b89e(%rip), %rax # 0xe24ec
movl $0x1, (%rax)
leaq 0x10(%rsp), %r14
movq %rsp, %r12
movl %ebp, %edi
movq %rbx, %rsi
leaq 0x77de8(%rip), %rdx # 0xdea50
leaq 0x771c1(%rip), %rcx # 0xdde30
... | /simonowen[P]samdisk/src/SAMdisk.cpp |
main | int main(int argc_, char* argv_[])
{
auto start_time = std::chrono::system_clock::now();
#ifdef _WIN32
#ifdef _DEBUG
_CrtSetDbgFlag(_CrtSetDbgFlag(_CRTDBG_REPORT_FLAG) | _CRTDBG_LEAK_CHECK_DF);
#endif
SetUnhandledExceptionFilter(CrashDumpUnhandledExceptionFilter);
#ifndef _DEBUG
// Check if we've bee... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r15
movl %edi, %r14d
callq 0x35070
movq %rax, %r12
movl %r14d, %edi
movq %r15, %rsi
callq 0x66c31
movl $0x1, %ebp
testb %al, %al
je 0x68c8e
leaq 0x7a3d2(%rip), %rbx # 0xe24e8
movslq (%rbx), %rax
cmpl %r14d, %eax
jge 0x681... | /simonowen[P]samdisk/src/SAMdisk.cpp |
util::LogHelper& util::operator<<<char [32]>(util::LogHelper&, char const (&) [32]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x692d5
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
util::LogHelper& util::operator<<<char [76]>(util::LogHelper&, char const (&) [76]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x6954b
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [19], char*&, char const (&) [2]>(char const (&) [19], char*&, char const (&) [2]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6afb2
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6a17b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x71a26(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [22], char*&, char const (&) [21]>(char const (&) [22], char*&, char const (&) [21]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6b524
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6a43f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x71762(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [25], char*&, char const (&) [15], int>(char const (&) [25], char*&, char const (&) [15], int&&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6b61d
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6a4b5
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x716ec(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [20], char*&, char const (&) [15], int>(char const (&) [20], char*&, char const (&) [15], int&&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6b718
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6a52b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x71676(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [35]>(char const (&) [35]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6b90c
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6a617
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x7158a(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::LogHelper& util::operator<<<char [1]>(util::LogHelper&, char const (&) [1]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x6a671
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::format<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const (&) [2]>(char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char con... | std::string format(T arg, Args&&... args)
{
using namespace std; // pull in to_string for other types
std::string s = to_string(arg) + format(std::forward<Args>(args)...);
return s;
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x90, %rsp
movq %rcx, %r14
movq %rdx, %r15
movq %rdi, %rbx
leaq 0x70(%rsp), %r12
leaq 0xf(%rsp), %rdx
movq %r12, %rdi
callq 0x5b424
leaq 0x40(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r12), %rsi
movq 0x8(%r12), %rdx
addq %rsi, %rdx
leaq 0x30(%rsp), %rdi
callq... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [28], char*&, char const (&) [15], int const&>(char const (&) [28], char*&, char const (&) [15], int const&) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x178, %rsp # imm = 0x178
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbx
movq %rsp, %rbp
movq %rbp, %rdi
callq 0x35760
movq %r13, %rdi
callq 0x35210
movq %rbp, %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [19], char*&, char const (&) [2]>(char const (&) [19], char*&, char const (&) [2]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x8(%rsp), %r13
movq %r13, %rdi
callq 0x35760
movq %r12, %rdi
callq 0x35210
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x356a0
movq (%r15), %r... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [21], char*&, char const (&) [35]>(char const (&) [21], char*&, char const (&) [35]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x8(%rsp), %r13
movq %r13, %rdi
callq 0x35760
movq %r12, %rdi
callq 0x35210
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x356a0
movq (%r15), %r... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [14], char*&, char const (&) [23]>(char const (&) [14], char*&, char const (&) [23]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x8(%rsp), %r13
movq %r13, %rdi
callq 0x35760
movq %r12, %rdi
callq 0x35210
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x356a0
movq (%r15), %r... | /simonowen[P]samdisk/include/utils.h |
SuperCardProUSB::Open() | std::unique_ptr<SuperCardPro> SuperCardProUSB::Open()
{
std::string path;
#ifdef _WIN32
path = SuperCardProWin32::GetDevicePath();
#elif defined(__linux__)
path = "/dev/ttyUSB0";
#elif defined(__APPLE__)
path = "/dev/cu.usbserial-SCP-JIM";
#endif
if (!path.empty())
{
int fd = open(path.... | pushq %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
movq $0x0, -0x8(%r14)
movb $0x0, (%r14)
leaq 0x4450b(%rip), %rcx # 0xafed6
movq %rsp, %rdi
movl $0xc, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x358f0
cmpq $0x0, 0x8(%rsp)
je 0x6ba1f
movq (%rsp), %rdi
mo... | /simonowen[P]samdisk/src/SCP_USB.cpp |
Sector::operator==(Sector const&) const | bool Sector::operator== (const Sector& sector) const
{
// Headers must match
if (sector.header != header)
return false;
// If neither has data it's a match
if (sector.m_data.size() == 0 && m_data.size() == 0)
return true;
// Both sectors must have some data
if (sector.copies() ... | pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
movq %r14, %rsi
callq 0x6079e
testb %al, %al
jne 0x6bc68
movq 0x28(%rbx), %rax
cmpq %rax, 0x30(%rbx)
jne 0x6bbee
movq 0x30(%r14), %rcx
cmpq 0x28(%r14), %rcx
je 0x6bca4
movq 0x30(%rbx), %rdx
subq %rax, %rdx
sarq $0x3, ... | /simonowen[P]samdisk/src/Sector.cpp |
Sector::add(Data&&, bool, unsigned char) | Sector::Merge Sector::add(Data&& new_data, bool bad_crc, uint8_t new_dam)
{
Merge ret = Merge::NewData;
// If the sector has a bad header CRC, it can't have any data
if (has_badidcrc())
return Merge::Unchanged;
#ifdef _DEBUG
// If there's enough data, check the CRC
if ((encoding == Encodin... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, 0x18(%rsp)
xorl %r15d, %r15d
cmpb $0x0, 0x21(%rdi)
jne 0x6c107
movl %ecx, %ebp
movl %edx, %r12d
movq %rdi, %rbx
testb %r12b, %r12b
je 0x6bdb3
movq %rbx, %rdi
callq 0x6c11e
testb %al, %al
jne 0x6c107
movl $0x2, %eax
testb %r12b... | /simonowen[P]samdisk/src/Sector.cpp |
Sector::merge(Sector&&) | Sector::Merge Sector::merge(Sector&& sector)
{
Merge ret = Merge::Unchanged;
// If the new header CRC is bad there's nothing we can use
if (sector.has_badidcrc())
return Merge::Unchanged;
// Something is wrong if the new details don't match the existing one
assert(sector.header == header);... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
xorl %ebp, %ebp
cmpb $0x0, 0x21(%rsi)
jne 0x6c26f
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
movq %r14, %rsi
callq 0x60772
testb %al, %al
je 0x6c280
movl 0x10(%rbx), %eax
cmpl 0x10(%r14), %eax
jne 0x6c29f
movl 0x14(%rbx), %eax
cmpl 0x14(%... | /simonowen[P]samdisk/src/Sector.cpp |
Sector::set_baddatacrc(bool) | void Sector::set_baddatacrc(bool bad)
{
m_bad_data_crc = bad;
if (!bad)
{
auto fill_byte = static_cast<uint8_t>((opt.fill >= 0) ? opt.fill : 0);
if (!has_data())
m_data.push_back(Data(size(), fill_byte));
else if (copies() > 1)
{
m_data.resize(1);
... | pushq %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movb %sil, 0x22(%rdi)
testl %esi, %esi
jne 0x6c4c5
movq %rdi, %r14
leaq 0x7338c(%rip), %rax # 0xdf740
movl 0x28(%rax), %eax
xorl %ecx, %ecx
testl %eax, %eax
cmovgl %eax, %ecx
movb %cl, 0x6(%rsp)
leaq 0x28(%rdi), %rbx
movq 0x30(%rdi), %rcx
subq 0x28(%rdi), %rcx
sarq ... | /simonowen[P]samdisk/src/Sector.cpp |
Sector::remove_gapdata(bool) | void Sector::remove_gapdata(bool keep_crc/*=false*/)
{
if (!has_gapdata())
return;
for (auto& data : m_data)
{
// If requested, attempt to preserve CRC bytes on bad sectors.
if (keep_crc && has_baddatacrc() && data.size() >= (size() + 2))
data.resize(size() + 2);
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %ebx
movq %rdi, %r14
callq 0x6c31a
testb %al, %al
je 0x6c564
movq 0x28(%r14), %r15
movq 0x30(%r14), %r12
cmpq %r12, %r15
je 0x6c564
testb %bl, %bl
je 0x6c53e
cmpb $0x1, 0x22(%r14)
jne 0x6c53e
movl 0x8(%r15), %ebp
subl (%r15), %ebp
movq %r14, %rdi
callq 0... | /simonowen[P]samdisk/src/Sector.cpp |
GenerateEmptyTrack(CylHead const&, Track const&) | TrackData GenerateEmptyTrack(const CylHead& cylhead, const Track& track)
{
assert(IsEmptyTrack(track));
(void)track;
// Generate a DD track full of gap filler. It shouldn't really matter
// which datarate and encoding as long as there are no sync marks.
BitstreamTrackBuilder bitbuf(DataRate::_250K,... | pushq %r15
pushq %r14
pushq %rbx
subq $0x80, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x713fc
testl %eax, %eax
jne 0x6ca91
movq %rsp, %r15
movq %r15, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x43910
movq %r15, %rdi
movl $0x4e, %esi
movl $0x186a, %edx # imm = 0x... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsKBI19Track(Track const&) | bool IsKBI19Track(const Track& track)
{
static const uint8_t ids[]{ 0,1,4,7,10,13,16,2,5,8,11,14,17,3,6,9,12,15,18,19 };
// CPC version has 19 sectors, PC version has 20 (with bad sector 19).
if (track.size() != arraysize(ids) && track.size() != arraysize(ids) - 1)
return false;
int idx = 0;
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
callq 0x713fc
cmpl $0x14, %eax
je 0x6cae9
movq %rbx, %rdi
callq 0x713fc
cmpl $0x13, %eax
jne 0x6cb83
movq %rbx, %rdi
callq 0x7140a
movq (%rax), %r14
movq 0x8(%rax), %r15
cmpq %r15, %r14
sete %bl
je 0x6cb61
xorl %ebp, %ebp
leaq 0x43977(%rip), %r12 ... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsSystem24Track(Track const&) | bool IsSystem24Track(const Track& track)
{
static const uint8_t sizes[] = { 4,4,4,4,4,3,1 };
auto i = 0;
if (track.size() != arraysize(sizes))
return false;
for (auto& s : track)
{
if (s.datarate != DataRate::_500K || s.encoding != Encoding::MFM ||
s.header.size != size... | pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
callq 0x713fc
cmpl $0x7, %eax
jne 0x6d098
movq 0x8(%r14), %rbx
movq 0x10(%r14), %r14
cmpq %r14, %rbx
je 0x6d074
xorl %ebp, %ebp
leaq 0x43459(%rip), %r15 # 0xb0494
xorl %eax, %eax
cmpl $0x7a120, 0x10(%rbx) # imm = 0x7A120
jne 0x6d067
cmpl $0x1... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateSystem24Track(CylHead const&, Track const&) | TrackData GenerateSystem24Track(const CylHead& cylhead, const Track& track)
{
assert(IsSystem24Track(track));
BitstreamTrackBuilder bitbuf(DataRate::_500K, Encoding::MFM);
for (auto& s : track)
{
auto gap3{ (s.header.sector < 6) ? 52 : 41 };
bitbuf.addSector(s, gap3);
}
return... | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x80, %rsp
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x6d011
testb %al, %al
je 0x6d188
movq %rsp, %rdi
movl $0x7a120, %esi # imm = 0x7A120
movl $0x1, %edx
callq 0x43910
movq 0x8(%r12), %r15
movq 0x10(%r12), %r13
cmpq %r13,... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateSpectrumSpeedlockTrack(CylHead const&, Track const&, int, int) | TrackData GenerateSpectrumSpeedlockTrack(const CylHead& cylhead, const Track& track, int weak_offset, int weak_size)
{
#ifdef _DEBUG
int temp_offset, temp_size;
assert(IsSpectrumSpeedlockTrack(track, temp_offset, temp_size));
assert(weak_offset == temp_offset && weak_size == temp_size);
#endif
FluxTrac... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp # imm = 0x118
movl %r8d, 0x4(%rsp)
movl %ecx, %ebx
movq %rdx, %r15
movq %rdi, 0x20(%rsp)
leaq 0xd0(%rsp), %r14
movq %r14, %rdi
movq %rsi, 0x38(%rsp)
movl $0x3d090, %edx # imm = 0x3D090
movl $0x1, %ecx
callq 0x5d8bc
m... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsCpcSpeedlockTrack(Track const&, int&, int&) | bool IsCpcSpeedlockTrack(const Track& track, int& weak_offset, int& weak_size)
{
if (track.size() != 9)
return false;
auto& sector0 = track[0];
auto& sector7 = track[7];
if (sector0.encoding != Encoding::MFM || sector7.encoding != Encoding::MFM ||
sector0.datarate != DataRate::_250K ||... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
callq 0x713fc
cmpl $0x9, %eax
jne 0x6d8db
xorl %ebp, %ebp
movq %r15, %rdi
xorl %esi, %esi
callq 0x71416
movq %rax, %r12
movq %r15, %rdi
movl $0x7, %esi
callq 0x71416
cmpl $0x1, 0x14(%r12)
jne 0x6... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateCpcSpeedlockTrack(CylHead const&, Track const&, int, int) | TrackData GenerateCpcSpeedlockTrack(const CylHead& cylhead, const Track& track, int weak_offset, int weak_size)
{
#ifdef _DEBUG
int temp_offset, temp_size;
assert(IsCpcSpeedlockTrack(track, temp_offset, temp_size));
assert(weak_offset == temp_offset && weak_size == temp_size);
#endif
FluxTrackBuilder f... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp # imm = 0x118
movl %r8d, 0x4(%rsp)
movl %ecx, %ebx
movq %rdx, %r15
movq %rdi, 0x20(%rsp)
leaq 0xd0(%rsp), %r14
movq %r14, %rdi
movq %rsi, 0x38(%rsp)
movl $0x3d090, %edx # imm = 0x3D090
movl $0x1, %ecx
callq 0x5d8bc
m... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsRainbowArtsTrack(Track const&, int&, int&) | bool IsRainbowArtsTrack(const Track& track, int& weak_offset, int& weak_size)
{
if (track.size() != 9)
return false;
auto& sector1 = track[1];
auto& sector3 = track[3];
if (sector1.encoding != Encoding::MFM || sector3.encoding != Encoding::MFM ||
sector1.datarate != DataRate::_250K || ... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
callq 0x713fc
cmpl $0x9, %eax
jne 0x6dcfe
movq %r15, %rdi
movl $0x1, %esi
callq 0x71416
movq %rax, %r12
movq %r15, %rdi
movl $0x3, %esi
callq 0x71416
xorl %ebp, %ebp
cmpl $0x1, 0x14(%r12)
jne 0x6dd00
movq %rax, %r15
c... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateRainbowArtsTrack(CylHead const&, Track const&, int, int) | TrackData GenerateRainbowArtsTrack(const CylHead& cylhead, const Track& track, int weak_offset, int weak_size)
{
#ifdef _DEBUG
int temp_offset, temp_size;
assert(IsRainbowArtsTrack(track, temp_offset, temp_size));
assert(weak_offset == temp_offset && weak_size == temp_size);
#endif
FluxTrackBuilder flu... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp # imm = 0x118
movl %r8d, 0x4(%rsp)
movl %ecx, %ebx
movq %rdx, %r15
movq %rdi, 0x20(%rsp)
leaq 0xd0(%rsp), %r14
movq %r14, %rdi
movq %rsi, 0x38(%rsp)
movl $0x3d090, %edx # imm = 0x3D090
movl $0x1, %ecx
callq 0x5d8bc
m... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsKBIWeakSectorTrack(Track const&, int&, int&) | bool IsKBIWeakSectorTrack(const Track& track, int& weak_offset, int& weak_size)
{
auto sectors = track.size();
// Most titles use the 10-sector version, but some have 3x2K sectors.
int size_code;
if (sectors == 3)
size_code = 4;
else if (sectors == 10)
size_code = 2;
else
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %rbx
movq %rsi, %r12
movq %rdi, %r15
callq 0x713fc
movl %eax, %r14d
cmpl $0x3, %eax
je 0x6e15f
cmpl $0xa, %r14d
jne 0x6e284
movq %r12, 0x8(%rsp)
movq %rbx, 0x10(%rsp)
movl $0x2, %ebp
jmp 0x6e16e
movq %r12, 0x8(%rsp)
movq %rbx,... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateKBIWeakSectorTrack(CylHead const&, Track const&, int, int) | TrackData GenerateKBIWeakSectorTrack(const CylHead& cylhead, const Track& track, int weak_offset, int weak_size)
{
#ifdef _DEBUG
int temp_offset, temp_size;
assert(IsKBIWeakSectorTrack(track, temp_offset, temp_size));
assert(weak_offset == temp_offset && weak_size == temp_size);
#endif
FluxTrackBuilder... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x128, %rsp # imm = 0x128
movl %r8d, 0xc(%rsp)
movl %ecx, %ebx
movq %rdx, %r15
movq %rdi, 0x10(%rsp)
leaq 0xe0(%rsp), %r14
movq %r14, %rdi
movq %rsi, 0x58(%rsp)
movl $0x3d090, %edx # imm = 0x3D090
movl $0x1, %ecx
callq 0x5d8bc
m... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsLogoProfTrack(Track const&) | bool IsLogoProfTrack(const Track& track)
{
// Accept track with or without placeholder sector
if (track.size() != 10 && track.size() != 11)
return false;
// First non-placeholder sector id.
int id = 2;
for (auto& s : track)
{
// Check for placeholder sector, present in old EDSK... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x713fc
cmpl $0xa, %eax
je 0x6e660
movq %rbx, %rdi
callq 0x713fc
cmpl $0xb, %eax
jne 0x6e756
movq 0x8(%rbx), %r14
movq 0x10(%rbx), %r15
cmpq %r15, %r14
je 0x6e6f2
movl $0x2, %r12d
movq %rbx, %rdi
callq 0x713fc
movl 0x8(%r... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateLogoProfTrack(CylHead const&, Track const&) | TrackData GenerateLogoProfTrack(const CylHead& cylhead, const Track& track)
{
assert(IsLogoProfTrack(track));
BitstreamTrackBuilder bitbuf(DataRate::_250K, Encoding::MFM);
bitbuf.addTrackStart();
bitbuf.addGap(600);
for (auto& sector : track)
{
if (sector.header.sector != 1)
... | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x80, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x6e637
testb %al, %al
je 0x6e863
movq %rsp, %r12
movq %r12, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x43910
movq %r12, %rdi
xorl %esi, %esi
callq... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsOperaSoftTrack(Track const&) | bool IsOperaSoftTrack(const Track& track)
{
uint32_t sector_mask = 0;
int i = 0;
if (track.size() != 9)
return false;
for (auto& s : track)
{
if (s.datarate != DataRate::_250K || s.encoding != Encoding::MFM)
return false;
static const uint8_t sizes[] = { 1,1,1,... | pushq %rbx
movq %rdi, %rbx
callq 0x713fc
cmpl $0x9, %eax
jne 0x6e942
movq 0x8(%rbx), %rcx
movq 0x10(%rbx), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
sete %sil
je 0x6e942
leaq 0x41be1(%rip), %rdi # 0xb04a8
xorl %r8d, %r8d
xorl %r9d, %r9d
cmpl $0x3d090, 0x10(%rcx) # imm = 0x3D090
jne 0x6e8fd
cmpl $0x1, 0x14(%rcx)
jne 0... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GenerateOperaSoftTrack(CylHead const&, Track const&) | TrackData GenerateOperaSoftTrack(const CylHead& cylhead, const Track& track)
{
assert(IsOperaSoftTrack(track));
BitstreamTrackBuilder bitbuf(DataRate::_250K, Encoding::MFM);
bitbuf.addTrackStart();
for (auto& sector : track)
{
if (sector.header.sector != 8)
bitbuf.addSector(sec... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x6e897
testb %al, %al
je 0x6eb7c
movq %r14, 0x18(%rsp)
leaq 0x28(%rsp), %r14
movq %r14, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x4391... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
Is8KSectorTrack(Track const&) | bool Is8KSectorTrack(const Track& track)
{
// There must only be 1 sector.
if (track.size() != 1)
return false;
auto& sector{ track[0] };
if (sector.datarate != DataRate::_250K || sector.encoding != Encoding::MFM ||
sector.size() != 8192 || !sector.has_data())
return false;
... | pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
callq 0x713fc
cmpl $0x1, %eax
jne 0x6ec45
xorl %ebx, %ebx
movq %r14, %rdi
xorl %esi, %esi
callq 0x71416
cmpl $0x3d090, 0x10(%rax) # imm = 0x3D090
jne 0x6ec47
movq %rax, %r14
cmpl $0x1, 0x14(%rax)
jne 0x6ec47
movq %r14, %rdi
callq 0x6bce0
cmpl $0x2000, %eax #... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
Generate8KSectorTrack(CylHead const&, Track const&) | TrackData Generate8KSectorTrack(const CylHead& cylhead, const Track& track)
{
assert(Is8KSectorTrack(track));
BitstreamTrackBuilder bitbuf(DataRate::_250K, Encoding::MFM);
bitbuf.addGap(16); // gap 4a
bitbuf.addIAM();
bitbuf.addGap(16); // gap 1
auto& sector{ track[0] };
bitbuf.addSector... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x6ebd7
testb %al, %al
je 0x6edbb
leaq 0x18(%rsp), %r12
movq %r12, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x43910
movq %r12, %rdi
movl $0x10, %esi
movl $0xf... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
IsPrehistorikTrack(Track const&) | bool IsPrehistorikTrack(const Track& track)
{
bool found_12{ false };
for (auto& s : track.sectors())
{
if (s.datarate != DataRate::_250K || s.encoding != Encoding::MFM ||
s.header.size != (s.has_baddatacrc() ? 5 : 2))
return false;
// The 4K sector 12 contains the ... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
callq 0x7140a
movq (%rax), %r14
movq 0x8(%rax), %r15
cmpq %r15, %r14
sete %bl
je 0x6eeac
xorl %r12d, %r12d
movl $0x75746954, %ebp # imm = 0x75746954
xorl %eax, %eax
cmpl $0x3d090, 0x10(%r14) # imm = 0x3D090
jne 0x6ee97
cmpl $0x1, 0x14... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
GeneratePrehistorikTrack(CylHead const&, Track const&) | TrackData GeneratePrehistorikTrack(const CylHead& cylhead, const Track& track)
{
assert(IsPrehistorikTrack(track));
BitstreamTrackBuilder bitbuf(DataRate::_250K, Encoding::MFM);
bitbuf.addTrackStart();
auto gap3 = (track.size() == 11) ? 106 : 30;
for (auto& sector : track)
{
if (sector... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdx, %r12
movq %rsi, %rbx
movq %rdi, %r14
movq %rdx, %rdi
callq 0x6ee0e
testb %al, %al
je 0x6f025
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x43910
movq %r15, %rdi
xorl ... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
Is11SectorTrack(Track const&) | bool Is11SectorTrack(const Track& track)
{
if (track.size() != 11)
return false;
for (auto& s : track)
{
if (s.datarate != DataRate::_250K || s.encoding != Encoding::MFM ||
s.size() != 512 || !s.has_good_data())
{
return false;
}
}
if (opt.de... | pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %r14
callq 0x713fc
cmpl $0xb, %eax
jne 0x6f0d9
movq 0x8(%r14), %rbx
movq 0x10(%r14), %r14
cmpq %r14, %rbx
sete %bpl
je 0x6f0b5
cmpl $0x3d090, 0x10(%rbx) # imm = 0x3D090
jne 0x6f0af
cmpl $0x1, 0x14(%rbx)
jne 0x6f0af
movq %rbx, %rdi
callq 0x6bce0
cmpl $0x200, %eax ... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
Generate11SectorTrack(CylHead const&, Track const&) | TrackData Generate11SectorTrack(const CylHead& cylhead, const Track& track)
{
assert(Is11SectorTrack(track));
BitstreamTrackBuilder bitbuf(DataRate::_250K, Encoding::MFM);
bitbuf.addTrackStart(true);
for (auto& sector : track)
bitbuf.addSector(sector, 1);
return TrackData(cylhead, std::mo... | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x80, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x6f05d
testb %al, %al
je 0x6f1c5
movq %rsp, %r12
movq %r12, %rdi
movl $0x3d090, %esi # imm = 0x3D090
movl $0x1, %edx
callq 0x43910
movq %r12, %rdi
movl $0x1, %esi
callq... | /simonowen[P]samdisk/src/SpecialFormat.cpp |
util::LogHelper& util::operator<<<char [35]>(util::LogHelper&, char const (&) [35]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x6f234
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
util::LogHelper& util::operator<<<char [30]>(util::LogHelper&, char const (&) [30]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x6f29d
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
util::LogHelper& util::operator<<<char [28]>(util::LogHelper&, char const (&) [28]) | LogHelper& operator<<(LogHelper& h, const T& t)
{
if (h.clearline)
{
h.clearline = false;
h << ttycmd::clearline;
}
*h.screen << t;
if (h.file && !h.statusmsg) *h.file << t;
return h;
} | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, 0x11(%rdi)
jne 0x6f36f
movb $0x0, 0x11(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x7897a
movq (%rbx), %r15
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
movq 0x8(%rbx), %r15
testq %r15, %r15
je 0x... | /simonowen[P]samdisk/include/utils.h |
MatchBlock(unsigned char const*, unsigned char const*, char const*) | static bool MatchBlock(const uint8_t* pbInput_, const uint8_t* pbMatch_, const char* psczRules_)
{
while (*psczRules_)
{
switch (*psczRules_++)
{
// Character must match
case 'y':
if (*pbInput_++ != *pbMatch_++)
return false;
break;
... | movb (%rdx), %cl
testb %cl, %cl
sete %al
je 0x6ff31
incq %rdx
cmpb $0x6e, %cl
je 0x6ff0d
movzbl %cl, %ecx
cmpl $0x6f, %ecx
je 0x6ff15
cmpl $0x79, %ecx
jne 0x6ff25
movb (%rdi), %cl
cmpb (%rsi), %cl
jne 0x6ff31
incq %rdi
incq %rsi
jmp 0x6ff25
movb (%rdi), %al
xorl %ecx, %ecx
cmpb (%rsi), %al
leaq 0x1(%rsi), %rsi
sete %cl... | /simonowen[P]samdisk/src/SpectrumPlus3.cpp |
SuperCardPro::Open() | std::unique_ptr<SuperCardPro> SuperCardPro::Open()
{
std::unique_ptr<SuperCardPro> p;
#ifdef HAVE_FTD2XX
if (!p)
p = SuperCardProFTD2XX::Open();
#endif
#ifdef HAVE_FTDI
if (!p)
p = SuperCardProFTDI::Open();
#endif
if (!p)
p = SuperCardProUSB::Open();
#ifdef _WIN32
if (!p)
... | pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq $0x0, (%rdi)
leaq 0x8(%rsp), %rdi
callq 0x6b9a4
movq 0x8(%rsp), %rax
movq $0x0, 0x8(%rsp)
movq %rax, (%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
retq
movq $0x0, (%rbx)
movq %rax, %rdi
callq 0x35aa0
| /simonowen[P]samdisk/src/SuperCardPro.cpp |
SuperCardPro::ReadExact(void*, int) | bool SuperCardPro::ReadExact(void* buf, int len)
{
uint8_t* p = reinterpret_cast<uint8_t*>(buf);
auto bytes_read = 0;
while (len > 0)
{
if (!Read(p, len, &bytes_read))
return false;
p += bytes_read;
len -= bytes_read;
}
return true;
} | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl $0x0, 0xc(%rsp)
testl %edx, %edx
setle %bpl
jle 0x70231
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
movq (%rdi), %rax
leaq 0xc(%rsp), %rcx
callq *0x10(%rax)
testb %al, %al
je 0x70231
leaq 0xc(%rsp), %r12
movslq 0xc(%rsp), %rax
movl %ebx, %... | /simonowen[P]samdisk/src/SuperCardPro.cpp |
SuperCardPro::WriteExact(void const*, int) | bool SuperCardPro::WriteExact(const void* buf, int len)
{
auto p = reinterpret_cast<const uint8_t*>(buf);
auto bytes_written = 0;
while (len > 0)
{
if (!Write(p, len, &bytes_written))
return false;
len -= bytes_written;
p += bytes_written;
}
#ifndef _WIN32
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl $0x0, 0xc(%rsp)
testl %edx, %edx
setle %bpl
jle 0x702a5
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
movq (%rdi), %rax
leaq 0xc(%rsp), %rcx
callq *0x18(%rax)
testb %al, %al
je 0x702af
leaq 0xc(%rsp), %r12
movslq 0xc(%rsp), %rax
movl %ebx, %... | /simonowen[P]samdisk/src/SuperCardPro.cpp |
SuperCardPro::SendCmd(unsigned char, void*, int, void*, int) | bool SuperCardPro::SendCmd(uint8_t cmd, void* buf, int len, void* bulkbuf, int bulklen)
{
auto p = reinterpret_cast<uint8_t*>(buf);
uint8_t datasum = CHECKSUM_INIT;
for (auto i = 0; i < len; ++i)
datasum += p[i];
Data data(2 + len + 1);
data[0] = cmd;
data[1] = static_cast<uint8_t>(len)... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %r9d, %r14d
movq %r8, %r15
movl %ecx, %r13d
movq %rdx, %r12
movl %esi, 0x4(%rsp)
movq %rdi, %rbx
testl %ecx, %ecx
jle 0x702f9
movl %r13d, %eax
movb $0x4a, %bpl
xorl %ecx, %ecx
addb (%r12,%rcx), %bpl
incq %rcx
cmpq %rcx, %rax
jne 0x7... | /simonowen[P]samdisk/src/SuperCardPro.cpp |
SuperCardPro::GetDriveStatus(int&) | bool SuperCardPro::GetDriveStatus(int& status)
{
uint16_t drv_status;
if (!SendCmd(CMD_STATUS))
return false;
if (!ReadExact(&drv_status, sizeof(drv_status)))
return false;
status = util::betoh(drv_status);
return true;
} | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
xorl %r15d, %r15d
movl $0x8e, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x702be
testb %al, %al
je 0x7069f
leaq 0xc(%rsp), %rcx
movl $0x0, (%rcx)
movq (%r14), %rax
leaq 0xa(%rsp), %r15... | /simonowen[P]samdisk/src/SuperCardPro.cpp |
util::exception::exception<char const (&) [28]>(char const (&) [28]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x711a0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x7104b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x6ab56(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
Track::data_extent_bits(Sector const&) const | int Track::data_extent_bits(const Sector& sector) const
{
auto it = find(sector);
assert(it != end());
auto drive_speed = (sector.datarate == DataRate::_300K) ? RPM_TIME_360 : RPM_TIME_300;
auto track_len = tracklen ? tracklen : GetTrackCapacity(drive_speed, sector.datarate, sector.encoding);
// A... | pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
callq 0x715cc
cmpq 0x10(%r14), %rax
je 0x715ac
movq %rax, %r15
movl (%r14), %eax
testl %eax, %eax
jne 0x7158c
movl 0x10(%rbx), %esi
movl 0x14(%rbx), %edx
cmpl $0x493e0, %esi # imm = 0x493E0
movl $0x28b0b, %eax # imm = 0x28B0B
movl $0x30d... | /simonowen[P]samdisk/src/Track.cpp |
Track::data_extent_bytes(Sector const&) const | int Track::data_extent_bytes(const Sector& sector) const
{
// We only support real data extent for MFM and FM sectors.
if (sector.encoding != Encoding::MFM && sector.encoding != Encoding::FM)
return sector.size();
auto encoding_shift = (sector.encoding == Encoding::FM) ? 5 : 4;
auto gap_bytes =... | pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movl 0x14(%rsi), %eax
leal -0x1(%rax), %ecx
cmpl $0x2, %ecx
jae 0x716bc
cmpl $0x2, %eax
sete %bpl
movq %rbx, %rsi
callq 0x7154e
movl %eax, %r14d
orb $0x4, %bpl
movl %ebp, %ecx
sarl %cl, %r14d
movl 0x14(%rbx), %edi
callq 0x60857
movl %eax, %ebp
movl 0x14(%rbx), %edi
callq... | /simonowen[P]samdisk/src/Track.cpp |
Track::has_good_data() const | bool Track::has_good_data() const
{
auto it = std::find_if(begin(), end(), [](const Sector& sector) {
if (sector.is_8k_sector() && sector.has_data())
{
const Data& data = sector.data_copy();
if (!ChecksumMethods(data.data(), data.size()).empty())
return false;... | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0x8(%rdi), %r14
movq 0x10(%rdi), %r12
movq %r12, %r13
subq %r14, %r13
sarq $0x8, %r13
testq %r13, %r13
jle 0x718d0
incq %r13
movq %r14, %rdi
callq 0x72954
testb %al, %al
jne 0x71908
leaq 0x40(%r14), %r15
movq %r15, %rdi
callq 0x72954
testb %al,... | /simonowen[P]samdisk/src/Track.cpp |
Track::clear() | void Track::clear()
{
*this = Track();
} | pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movq %rsp, %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x713b8
movq (%r14), %rax
movq %rax, (%rbx)
leaq 0x8(%rsp), %r14
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %rdi
movaps %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq 0x8(%rbx), %rax
movups 0x10(%rbx), %xmm0
movq (%r14), %rc... | /simonowen[P]samdisk/src/Track.cpp |
Track::format(CylHead const&, Format const&) | Track& Track::format(const CylHead& cylhead, const Format& fmt)
{
assert(fmt.sectors != 0);
m_sectors.clear();
m_sectors.reserve(fmt.sectors);
for (auto id : fmt.get_ids(cylhead))
{
Header header(cylhead.cyl, cylhead.head ? fmt.head1 : fmt.head0, id, fmt.size);
Sector sector(fmt.da... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
cmpl $0x0, 0x14(%rdx)
je 0x71f73
movq %rdx, %r14
movq %rsi, %r15
leaq 0x8(%rdi), %rbx
movq 0x8(%rdi), %r12
movq %rdi, 0x10(%rsp)
movq 0x10(%rdi), %r13
cmpq %r12, %r13
je 0x71e41
movq %r12, %rbp
leaq 0x28(%rbp), %rdi
callq 0x410b8
addq $0... | /simonowen[P]samdisk/src/Track.cpp |
Track::insert(int, Sector&&) | void Track::insert(int index, Sector&& sector)
{
assert(index <= static_cast<int>(m_sectors.size()));
if (!m_sectors.empty() && m_sectors[0].datarate != sector.datarate)
throw util::exception("can't mix datarates on a track");
auto it = m_sectors.begin() + index;
m_sectors.insert(it, std::move... | pushq %r14
pushq %rbx
pushq %rax
movl %esi, %eax
movq 0x8(%rdi), %rsi
movq 0x10(%rdi), %rcx
movq %rcx, %r8
subq %rsi, %r8
shrq $0x6, %r8
cmpl %eax, %r8d
jl 0x721ff
cmpq %rcx, %rsi
je 0x721e6
movl 0x10(%rsi), %ecx
cmpl 0x10(%rdx), %ecx
jne 0x7221e
addq $0x8, %rdi
cltq
shlq $0x6, %rax
addq %rax, %rsi
addq $0x8, %rsp
popq... | /simonowen[P]samdisk/src/Track.cpp |
Track::find(Header const&) | std::vector<Sector>::iterator Track::find(const Header& header)
{
return std::find_if(begin(), end(), [&](const Sector& s) {
return header == s.header;
});
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq 0x8(%rdi), %rbx
movq 0x10(%rdi), %r12
movq %r12, %r13
subq %rbx, %r13
sarq $0x8, %r13
testq %r13, %r13
jle 0x7244a
incq %r13
movq %r14, %rdi
movq %rbx, %rsi
callq 0x60772
testb %al, %al
jne 0x72488
leaq 0x40(%rbx), %r15
movq %r14, %rdi
movq %r1... | /simonowen[P]samdisk/src/Track.cpp |
util::fmt[abi:cxx11](char const*, ...) | std::string fmt(const char* fmt, ...)
{
va_list args;
va_start(args, fmt);
auto len = std::vsnprintf(nullptr, 0, fmt, args);
va_end(args);
std::vector<char> bytes(len + 1); // +1 for \0
va_start(args, fmt);
std::vsnprintf(&bytes[0], bytes.size(), fmt, args);
va_end(args);
return s... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x40(%rsp), %rbp
movq %rdx, 0x10(%rbp)
movq %rcx, 0x18(%rbp)
movq %r8, 0x20(%rbp)
movq %r9, 0x28(%rbp)
testb %al, %al
je 0x78539
movaps %xmm0, 0x70(%rsp)
movaps %xmm1, 0x80(%rsp)
movaps %xmm2, 0x90(%r... | /simonowen[P]samdisk/src/utils.cpp |
util::lowercase(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | std::string lowercase(const std::string& str)
{
std::string ret = str;
ret.reserve(str.length());
std::transform(str.cbegin(), str.cend(), ret.begin(), [](char c) {
return static_cast<uint8_t>(std::tolower(static_cast<int>(c)));
});
return ret;
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rdi), %r15
movq %r15, (%rdi)
movq (%rsi), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
callq 0x41ad6
movq 0x8(%r14), %rsi
movq %rbx, %rdi
callq 0x35910
movq 0x8(%r14), %r15
testq %r15, %r15
je 0x788bf
movq (%r14), %r14
movq (... | /simonowen[P]samdisk/src/utils.cpp |
util::operator<<(util::LogHelper&, colour) | LogHelper& operator<<(LogHelper& h, colour c)
{
// Colours are screen only
if (util::is_stdout_a_tty())
{
#ifdef _WIN32
h.screen->flush();
SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), static_cast<int>(c));
#else
auto val = static_cast<int>(c);
if (val & 0x80)
... | pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebp
movq %rdi, %rbx
callq 0x78849
testb %al, %al
je 0x7896e
movzbl %bpl, %ebp
movq (%rbx), %r14
testb %bpl, %bpl
js 0x78939
leaq 0x3865f(%rip), %rsi # 0xb0f72
movl $0x4, %edx
movq %r14, %rdi
callq 0x356a0
movq %r14, %rdi
movl %ebp, %esi
callq 0x35a80
lea... | /simonowen[P]samdisk/src/utils.cpp |
util::operator<<(util::LogHelper&, ttycmd) | LogHelper& operator<<(LogHelper& h, ttycmd cmd)
{
if (util::is_stdout_a_tty())
{
switch (cmd)
{
case ttycmd::statusbegin:
h.statusmsg = true;
break;
case ttycmd::statusend:
h.statusmsg = false;
h.clearline = true;
break... | pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %rbx
callq 0x78849
testb %al, %al
je 0x789fd
cmpb $0x3, %bpl
ja 0x789fd
movzbl %bpl, %eax
leaq 0x3859f(%rip), %rcx # 0xb0f3c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq (%rbx), %rdi
leaq 0x385c7(%rip), %rsi # 0xb0f77
movl $0x4, %edx
call... | /simonowen[P]samdisk/src/utils.cpp |
Read2D(MemFile&, std::shared_ptr<Disk>&) | bool Read2D(MemFile& file, std::shared_ptr<Disk>& disk)
{
Format fmt{ RegularFormat::_2D };
if (!IsFileExt(file.name(), "2d") || file.size() != fmt.disk_size())
return false;
file.rewind();
disk->format(fmt, file.data());
disk->strType = "2D";
return true;
} | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x2c(%rsp), %rdi
movl $0x19, %esi
callq 0x5db04
movq %r14, %rdi
callq 0x64ca2
movq %rax, %r15
leaq 0x18(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x384dd(%rip), %rsi # 0xb0fc7
leaq 0x384d8(%rip), %r... | /simonowen[P]samdisk/src/types/2d.cpp |
void Message<unsigned long, char const*, unsigned char&, unsigned char&, unsigned char&, unsigned char&, unsigned int&>(MsgType, char const*, unsigned long&&, char const*&&, unsigned char&, unsigned char&, unsigned char&, unsigned char&, unsigned int&) | void Message(MsgType type, const char* pcsz_, Args&& ...args)
{
std::string msg = util::fmt(pcsz_, std::forward<Args>(args)...);
if (type == msgError)
throw util::exception(msg);
if (type != msgStatus)
{
if (seen_messages.find(msg) != seen_messages.end())
return;
s... | pushq %r14
pushq %rbx
subq $0x28, %rsp
movl %edi, %ebx
movq 0x50(%rsp), %rax
movq 0x48(%rsp), %rdi
movq 0x40(%rsp), %r10
movq (%rdx), %rdx
movq (%rcx), %rcx
movzbl (%r8), %r8d
movzbl (%r9), %r9d
movzbl (%r10), %r10d
movzbl (%rdi), %r11d
movl (%rax), %r14d
subq $0x8, %rsp
leaq 0x10(%rsp), %rdi
xorl %eax, %eax
pushq %r14... | /simonowen[P]samdisk/include/Util.h |
ReadBlockDevice(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::shared_ptr<Disk>&) | bool ReadBlockDevice(const std::string& path, std::shared_ptr<Disk>& disk)
{
if (!IsBlockDevice(path))
return false;
auto blockdev = std::make_unique<BlockDevice>();
if (!blockdev->Open(path, true))
return false;
Format fmt;
if (!Format::FromSize(blockdev->total_bytes, fmt))
... | pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rsi, %rbx
movq %rdi, %r14
callq 0x76f0f
testb %al, %al
je 0x7ab03
movl $0x2b8, %edi # imm = 0x2B8
callq 0x355b0
movq %rax, %r15
movq %rax, %rdi
callq 0x43aac
movq %r15, (%rsp)
movq %r15, %rdi
movq %r14, %rsi
movl $0x1, %edx
callq 0... | /simonowen[P]samdisk/src/types/blk_dev.cpp |
util::exception::exception<char const (&) [25], int&>(char const (&) [25], int&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x7acbf
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x7ac53
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x60f4e(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
complete(Track&) | static Track& complete(Track& track)
{
uint8_t fill = 0;
for (auto& sector : track)
{
// Add test data to sectors that lack it
if (!sector.copies())
sector.add(Data(sector.size(), fill));
// Remove data from sectors with 0 bytes of data (for no-data sectors)
els... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movb $0x0, 0xe(%rsp)
movq 0x8(%rdi), %r14
movq 0x10(%rdi), %rbp
cmpq %rbp, %r14
je 0x83f8c
leaq 0x10(%rsp), %r15
leaq 0xe(%rsp), %r12
leaq 0xf(%rsp), %r13
movq %r14, %rdi
callq 0x6bcaa
movq %r14, %rdi
testl %eax, %eax
je ... | /simonowen[P]samdisk/src/types/builtin.cpp |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [22]>(char const (&) [22]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x58b06(%rip... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [31], int&>(char const (&) [31], int&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x84b07
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x849e3
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x571be(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [42]>(char const (&) [42]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x58387(%rip... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [27]>(char const (&) [27]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x582f2(%rip... | /simonowen[P]samdisk/include/utils.h |
ReadCPM(MemFile&, std::shared_ptr<Disk>&) | bool ReadCPM(MemFile& file, std::shared_ptr<Disk>& disk)
{
Format fmt = RegularFormat::ProDos;
// 720K images with a .cpm extension use the SAM Coupe Pro-Dos parameters
if (file.size() != fmt.disk_size() || !IsFileExt(file.name(), "cpm"))
return false;
file.rewind();
disk->format(fmt, file... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x2c(%rsp), %r12
movq %r12, %rdi
movl $0x1, %esi
callq 0x5db04
movq %r14, %rdi
callq 0x64c8e
movl %eax, %r15d
movq %r12, %rdi
callq 0x5e142
movl %eax, %r12d
movb $0x1, %bpl
cmpl %eax, %r15d
jne 0x84d5... | /simonowen[P]samdisk/src/types/cpm.cpp |
util::exception::exception<char const (&) [17]>(char const (&) [17]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x8606e
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x85e4b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x55d56(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [20], unsigned long>(char const (&) [20], unsigned long&&) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x178, %rsp # imm = 0x178
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rsp, %r12
movq %r12, %rdi
callq 0x35760
movq %r15, %rdi
callq 0x35210
movq %r12, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x356a0
movq (%r14), %rsi
movq %rsp, %rdi
callq 0x353c0... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [22], unsigned char&, char const (&) [12], unsigned char&>(char const (&) [22], unsigned char&, char const (&) [12], unsigned char&) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x178, %rsp # imm = 0x178
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbx
movq %rsp, %rbp
movq %rbp, %rdi
callq 0x35760
movq %r13, %rdi
callq 0x35210
movq %rbp, %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [26], unsigned char&>(char const (&) [26], unsigned char&) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x178, %rsp # imm = 0x178
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rsp, %r12
movq %r12, %rdi
callq 0x35760
movq %r15, %rdi
callq 0x35210
movq %r12, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x356a0
movzbl (%r14), %esi
movq %rsp, %rdi
callq 0x35a... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [52]>(char const (&) [52]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x5605c(%rip... | /simonowen[P]samdisk/include/utils.h |
ReadD2M(MemFile&, std::shared_ptr<Disk>&) | bool ReadD2M(MemFile& file, std::shared_ptr<Disk>& disk)
{
// D2M is a fixed-size image
uint8_t ab[256];
if (file.size() != D2M_DISK_SIZE || !file.seek(D2M_PARTITION_OFFSET) || !file.read(&ab, sizeof(ab)))
return false;
// Check a partition starts at track 1 sector 1, with "SYSTEM" name
if ... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x148, %rsp # imm = 0x148
movq %rsi, %rbx
movq %rdi, %r14
callq 0x64c8e
cmpl $0x195000, %eax # imm = 0x195000
jne 0x87165
movq %r14, %rdi
movl $0x190800, %esi # imm = 0x190800
callq 0x64dce
testb %al, %al
je 0x87165
leaq 0x40(%rsp), %rsi
movq ... | /simonowen[P]samdisk/src/types/d2m.cpp |
ReadD4M(MemFile&, std::shared_ptr<Disk>&) | bool ReadD4M(MemFile& file, std::shared_ptr<Disk>& disk)
{
// D4M is a fixed-size image
uint8_t ab[256];
if (file.size() != D4M_DISK_SIZE || !file.seek(D4M_PARTITION_OFFSET) || !file.read(&ab, sizeof(ab)))
return false;
// Check a partition starts at track 1 sector 1, with "SYSTEM" name
if ... | pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x148, %rsp # imm = 0x148
movq %rsi, %rbx
movq %rdi, %r14
callq 0x64c8e
cmpl $0x32a000, %eax # imm = 0x32A000
jne 0x872a9
movq %r14, %rdi
movl $0x320800, %esi # imm = 0x320800
callq 0x64dce
testb %al, %al
je 0x872a9
leaq 0x40(%rsp), %rsi
movq ... | /simonowen[P]samdisk/src/types/d4m.cpp |
util::exception::exception<char const (&) [20], CylHead&>(char const (&) [20], CylHead&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x88f21
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88dfd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x52da4(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [23], unsigned char&, char const (&) [6], CylHead&>(char const (&) [23], unsigned char&, char const (&) [6], CylHead&) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x89029
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88e73
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x52d2e(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [39]>(char const (&) [39]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x8a4b3
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x89831
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x52370(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
util::exception::exception<char const (&) [20], CylHead&, char const (&) [6]>(char const (&) [20], CylHead&, char const (&) [6]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x8a548
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x898a7
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x522fa(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [46]>(char const (&) [46]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %rbx
subq $0x180, %rsp # imm = 0x180
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x35760
movq %r14, %rdi
callq 0x35210
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x356a0
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x35920
movq 0x5305a(%rip... | /simonowen[P]samdisk/include/utils.h |
DFIDisk::~DFIDisk() | void add_track_data(const CylHead& cylhead, Data&& data)
{
// Determine image clock rate if not yet known. It seems reasonable
// to assume this will not vary between tracks.
if (!m_tick_ns)
{
uint32_t index_pos = 0;
for (auto byte : data)
{
... | pushq %rbx
movq %rdi, %rbx
addq $0x110, %rdi # imm = 0x110
callq 0x8a2c0
movq %rbx, %rdi
popq %rbx
jmp 0x53fd2
nop
| /simonowen[P]samdisk/src/types/dfi.cpp |
DFIDisk::~DFIDisk() | void add_track_data(const CylHead& cylhead, Data&& data)
{
// Determine image clock rate if not yet known. It seems reasonable
// to assume this will not vary between tracks.
if (!m_tick_ns)
{
uint32_t index_pos = 0;
for (auto byte : data)
{
... | pushq %rbx
movq %rdi, %rbx
addq $0x110, %rdi # imm = 0x110
callq 0x8a2c0
movq %rbx, %rdi
callq 0x53fd2
movl $0x148, %esi # imm = 0x148
movq %rbx, %rdi
popq %rbx
jmp 0x355d0
| /simonowen[P]samdisk/src/types/dfi.cpp |
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> util::make_string<char const (&) [20], CylHead&, char const (&) [6]>(char const (&) [20], CylHead&, char const (&) [6]) | std::string make_string(Args&& ... args)
{
std::ostringstream ss;
(void)std::initializer_list<bool> {(ss << args, false)...};
return ss.str();
} | pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1a0, %rsp # imm = 0x1A0
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x28(%rsp), %r13
movq %r13, %rdi
callq 0x35760
movq %r12, %rdi
callq 0x35210
movq %r13, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x356a0
movl (%r15), %... | /simonowen[P]samdisk/include/utils.h |
ReadDMK(MemFile&, std::shared_ptr<Disk>&) | bool ReadDMK(MemFile& file, std::shared_ptr<Disk>& disk)
{
DMK_HEADER dh{};
if (!file.rewind() || !file.read(&dh, sizeof(dh)))
return false;
else if ((dh.protect != 0x00 && dh.protect != 0xff))
return false;
bool ignore_density = (dh.flags & 0x80) != 0;
bool single_density = (dh.fla... | pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp # imm = 0x138
movq %rsi, 0x58(%rsp)
movq %rdi, %r13
xorps %xmm0, %xmm0
movaps %xmm0, 0x40(%rsp)
callq 0x64db2
testb %al, %al
je 0x8a6f3
leaq 0x40(%rsp), %rsi
movq %r13, %rdi
movl $0x10, %edx
callq 0x64d0c
testb %al, %al
je 0x... | /simonowen[P]samdisk/src/types/dmk.cpp |
util::exception::exception<char const (&) [51]>(char const (&) [51]) | explicit exception(Args&& ... args)
: std::runtime_error(make_string(std::forward<Args>(args)...)) {} | pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x8b2f6
movq %rbx, %rdi
movq %r14, %rsi
callq 0x35710
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8b0ff
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x355d0
leaq 0x50aa2(%rip), %rax # 0xdbba8
movq %rax, ... | /simonowen[P]samdisk/include/utils.h |
void Message<int, int&>(MsgType, char const*, int&&, int&) | void Message(MsgType type, const char* pcsz_, Args&& ...args)
{
std::string msg = util::fmt(pcsz_, std::forward<Args>(args)...);
if (type == msgError)
throw util::exception(msg);
if (type != msgStatus)
{
if (seen_messages.find(msg) != seen_messages.end())
return;
s... | pushq %r14
pushq %rbx
subq $0x28, %rsp
movl %edi, %ebx
movl (%rdx), %edx
movl (%rcx), %ecx
leaq 0x8(%rsp), %rdi
xorl %eax, %eax
callq 0x784cc
testl %ebx, %ebx
je 0x8b232
cmpl $0x4, %ebx
je 0x8b28f
leaq 0x54c90(%rip), %r14 # 0xdfdf8
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x418a4
addq $0x8, %r14
cmpq %r14, %rax
j... | /simonowen[P]samdisk/include/Util.h |
Subsets and Splits
SQL Console for LLM4Binary/decompile-bench
Filters out entries with file names ending in .cpp, providing a basic subset of the dataset that excludes C++ files.