{"name": "ide_dma_restart_bh", "code": "__int64 __fastcall ide_dma_restart_bh ( __int64 @@a1@@ ) { __int64 v1 ; __int64 result ; __int64 v3 ; _BOOL4 @@v4@@ ; qemu_bh_delete ( * ( _QWORD * ) ( @@a1@@ + Number ) ) ; * ( _QWORD * ) ( @@a1@@ + Number ) = Number L ; @@v4@@ = ( * ( _BYTE * ) ( @@a1@@ + Number ) & Number ) != Number ; if ( ( * ( _BYTE * ) ( @@a1@@ + Number ) & Number ) != Number ) { * ( _BYTE * ) ( @@a1@@ + Number ) &= Number ; v1 = bmdma_active_if ( @@a1@@ ) ; result = ide_dma_restart ( v1 , @@v4@@ ) ; } else { result = * ( _BYTE * ) ( @@a1@@ + Number ) & Number ; if ( ( * ( _BYTE * ) ( @@a1@@ + Number ) & Number ) != Number ) { * ( _BYTE * ) ( @@a1@@ + Number ) &= Number ; v3 = bmdma_active_if ( @@a1@@ ) ; if ( @@v4@@ ) result = ide_sector_read ( v3 ) ; else result = ide_sector_write ( v3 ) ; } } return result ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "v4", "t": {"T": 1, "n": "_BOOL4", "s": 4}, "location": "s12"}]}
{"name": "bmdma_active_if", "code": "__int64 __fastcall bmdma_active_if ( __int64 @@a1@@ ) { if ( * ( _BYTE * ) ( @@a1@@ + Number ) == Number ) _assert_fail ( String , String , Number , String ) ; return * ( _QWORD * ) ( @@a1@@ + Number ) + Number L + Number L * * ( unsigned __int8 * ) ( @@a1@@ + Number ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}]} {"name": "ide_sector_read", "code": "__int64 __fastcall ide_sector_read ( __int64 @@a1@@ ) { __int64 @@result@@ ; int @@v2@@ ; unsigned __int64 @@v3@@ ; unsigned int @@v4@@ ; * ( _BYTE * ) ( @@a1@@ + Number ) = Number ; * ( _BYTE * ) ( @@a1@@ + Number ) = Number ; @@v3@@ = ide_get_sector ( @@a1@@ ) ; @@v4@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; if ( ! @@v4@@ ) return ide_transfer_stop ( @@a1@@ ) ; if ( ( signed int ) @@v4@@ > * ( _DWORD * ) ( @@a1@@ + Number ) ) @@v4@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; @@v2@@ = bdrv_read ( * ( _QWORD * ) ( @@a1@@ + Number ) , @@v3@@ , * ( _QWORD * ) ( @@a1@@ + Number ) , @@v4@@ ) ; if ( ! @@v2@@ || ( @@result@@ = ide_handle_rw_error ( @@a1@@ , ( unsigned int ) - @@v2@@ , Number L ) , ! ( _DWORD ) @@result@@ ) ) { ide_transfer_start ( @@a1@@ , * ( _QWORD * ) ( @@a1@@ + Number ) , @@v4@@ << Number , ( __int64 ) ide_sector_read ) ; ide_set_irq ( * ( _QWORD * ) @@a1@@ ) ; ide_set_sector ( @@a1@@ , @@v3@@ + ( int ) @@v4@@ ) ; @@result@@ = @@a1@@ ; * ( _DWORD * ) ( @@a1@@ + Number ) -= @@v4@@ ; } return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "result", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r8"}, {"n": "v3", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s16"}, {"n": "v2", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v4", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4"}]} {"name": "ide_sector_write", "code": "__int64 __fastcall ide_sector_write ( __int64 @@a1@@ ) { __int64 @@result@@ ; int @@v2@@ ; unsigned __int64 @@v3@@ ; int @@v4@@ ; unsigned int @@v5@@ ; * ( _BYTE * ) ( @@a1@@ + Number ) = Number ; @@v3@@ = ide_get_sector ( @@a1@@ ) ; @@v5@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; if ( ( signed int ) @@v5@@ > * ( _DWORD * ) ( @@a1@@ + Number ) ) @@v5@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; @@v2@@ = bdrv_write ( * ( _QWORD * ) ( @@a1@@ + Number ) , @@v3@@ , * ( _QWORD * ) ( @@a1@@ + Number ) , @@v5@@ ) ; if ( ! @@v2@@ || ( @@result@@ = ide_handle_rw_error ( ( __int64 * ) @@a1@@ , - @@v2@@ , Number ) , ! ( _DWORD ) @@result@@ ) ) { * ( _DWORD * ) ( @@a1@@ + Number ) -= @@v5@@ ; if ( * ( _DWORD * ) ( @@a1@@ + Number ) ) { @@v4@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; if ( @@v4@@ > * ( _DWORD * ) ( @@a1@@ + Number ) ) @@v4@@ = * ( _DWORD * ) ( @@a1@@ + Number ) ; ide_transfer_start ( @@a1@@ , * ( _QWORD * ) ( @@a1@@ + Number ) , @@v4@@ << Number , ( __int64 ) ide_sector_write ) ; } else { ide_transfer_stop ( @@a1@@ ) ; } ide_set_sector ( @@a1@@ , @@v3@@ + ( int ) @@v5@@ ) ; @@result@@ = ide_set_irq ( * ( _QWORD * ) @@a1@@ ) ; } return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "result", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r8"}, {"n": "v3", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s16"}, {"n": "v2", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v5", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4"}, {"n": "v4", "t": {"T": 1, "n": "int", "s": 4}, "location": "s8"}]} {"name": "ide_dma_restart_cb", "code": "__int64 __fastcall ide_dma_restart_cb ( __int64 @@a1@@ , int @@a2@@ ) { __int64 @@result@@ ; @@result@@ = @@a1@@ ; if ( @@a2@@ ) { @@result@@ = * ( _QWORD * ) ( @@a1@@ + Number ) ; if ( ! @@result@@ ) { * ( _QWORD * ) ( @@a1@@ + Number ) = qemu_bh_new ( ide_dma_restart_bh , @@a1@@ ) ; @@result@@ = qemu_bh_schedule ( * ( _QWORD * ) ( @@a1@@ + Number ) ) ; } } return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "int", "s": 4}, "location": "r64"}, {"n": "result", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r8"}]} {"name": "ide_dma_restart", "code": "__int64 __fastcall ide_dma_restart ( _DWORD * @@a1@@ , int @@a2@@ ) { __int64 @@v3@@ ; @@v3@@ = * ( _QWORD * ) ( * ( _QWORD * ) @@a1@@ + Number L ) ; ide_set_sector ( ( __int64 ) @@a1@@ , * ( _QWORD * ) ( @@v3@@ + Number ) ) ; @@a1@@ [ Number ] = Number ; @@a1@@ [ Number ] = Number ; @@a1@@ [ Number ] = * ( _DWORD * ) ( @@v3@@ + Number ) ; * ( _DWORD * ) ( @@v3@@ + Number ) = * ( _DWORD * ) ( @@v3@@ + Number ) ; if ( @@a2@@ ) * ( _QWORD * ) ( @@v3@@ + Number ) = ide_read_dma_cb ; else * ( _QWORD * ) ( @@v3@@ + Number ) = ide_write_dma_cb ; return ide_dma_start ( ( __int64 ) @@a1@@ , * ( _QWORD * ) ( @@v3@@ + Number ) ) ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "_DWORD"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "int", "s": 4}, "location": "r64"}, {"n": "v3", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s8"}]}