Author: tkreuzer Date: Thu Feb 4 05:58:09 2010 New Revision: 45410
URL: http://svn.reactos.org/svn/reactos?rev=45410&view=rev Log: [AMD64] Switch from underscore prefixed symbols to unprefixed symbols. (MSVC compatibility)
Modified: branches/ros-amd64-bringup/reactos/ReactOS-amd64.rbuild branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/arch.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/boot.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/drvmap.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386cpu.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386pnp.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386trap.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/int386.S branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/mb.S branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/irq.S branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/systimer.S branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/mps.S branches/ros-amd64-bringup/reactos/include/reactos/asm.h branches/ros-amd64-bringup/reactos/lib/drivers/oskittcp/include/freebsd/src/sys/sys/kernel.h branches/ros-amd64-bringup/reactos/lib/rtl/amd64/debug_asm.S branches/ros-amd64-bringup/reactos/lib/rtl/amd64/except_asm.S branches/ros-amd64-bringup/reactos/lib/rtl/amd64/rtlmem.S branches/ros-amd64-bringup/reactos/lib/rtl/amd64/slist.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/except/amd64/chkstk_asm.s branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/alldiv.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan2.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceil.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceilf.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/exp.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fabs.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floor.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floorf.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmod.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmodf.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ldexp.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log10.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/pow.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrt.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrtf.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/tan.S branches/ros-amd64-bringup/reactos/lib/sdk/crt/setjmp/amd64/setjmp.s branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/boot.S branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/ctxswitch.S branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/trap.S branches/ros-amd64-bringup/reactos/ntoskrnl/mm/amd64/page.c branches/ros-amd64-bringup/reactos/tools/nci/ncitool.c branches/ros-amd64-bringup/reactos/tools/rbuild/backend/mingw/linkers/ld.mak branches/ros-amd64-bringup/reactos/tools/rbuild/module.cpp
Modified: branches/ros-amd64-bringup/reactos/ReactOS-amd64.rbuild URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ReactO... ============================================================================== --- branches/ros-amd64-bringup/reactos/ReactOS-amd64.rbuild [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/ReactOS-amd64.rbuild [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -34,6 +34,7 @@ <!-- compilerflag compiler="as">-gstabs+</compilerflag --> <compilerflag>-U_X86_</compilerflag> <compilerflag>-Wno-format</compilerflag> + <compilerflag>-fno-leading-underscore</compilerflag> </group>
<group linkerset="ld"> @@ -42,6 +43,8 @@ <linkerflag>-section-alignment=0x1000</linkerflag> <linkerflag>--unique=.eh_frame</linkerflag> <linkerflag>-static</linkerflag> + <linkerflag>-fno-leading-underscore</linkerflag> + <linkerflag>--exclude-all-symbols</linkerflag> </group>
<if property="USERMODE" value="1">
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/arch.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/arch.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/arch.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -21,22 +21,22 @@ mov ss, ax
/* checkPoint Charlie - where it all began... */ - mov si, offset _CheckPoint0 + mov si, offset CheckPoint0 call writestr - + /* Setup a real mode stack */ mov sp, stack16
/* Zero BootDrive and BootPartition */ xor eax, eax - mov _BootDrive, eax - mov _BootPartition, eax + mov BootDrive, eax + mov BootPartition, eax
/* Store the boot drive */ - mov _BootDrive, dl + mov BootDrive, dl
/* Store the boot partition */ - mov _BootPartition, dh + mov BootPartition, dh
/* Load the GDT */ lgdt gdtptr @@ -46,13 +46,13 @@ call x86_16_EnableA20
/* checkPoint Charlie - where it all began... */ - mov si, offset _CheckPoint1 + mov si, offset CheckPoint1 call writestr call x86_16_BuildPageTables /* checkPoint Charlie - where it all began... */ - mov si, offset _CheckPoint2 + mov si, offset CheckPoint2 call writestr
/* Check if CPU supports CPUID */ @@ -89,26 +89,26 @@ /* X64 Processor */ /* checkPoint Charlie - where it all began... */ - mov si, offset _CheckPoint3 + mov si, offset CheckPoint3 call writestr
- jmp _switch64 + jmp switch64 NO_X64_SUPPORT_DETECTED: - mov si, offset _NotAnX64Processor // Loading message + mov si, offset NotAnX64Processor // Loading message call writestr - jmp _fail + jmp fail
NO_CPUID_SUPPORT_DETECTED: - mov si, offset _NoCPUIDSupport // Loading message - call writestr - -_fail: - jmp _fail + mov si, offset NoCPUIDSupport // Loading message + call writestr + +fail: + jmp fail nop nop
-_switch64: +switch64: call x86_16_SwitchToLong
.code64 @@ -119,7 +119,7 @@
/* GO! */ xor rcx, rcx - call _BootMain + call BootMain
/* Checkpoint */ // mov ax, LMODE_DS @@ -174,14 +174,14 @@ push es
/* Get segment of pml4 */ - mov eax, offset _pml4_startup + mov eax, offset pml4_startup shr eax, 4 mov es, ax cld xor di, di
/* One entry in the PML4 pointing to PDP */ - mov eax, offset _pdp_startup + mov eax, offset pdp_startup or eax, 0x00f stosd /* clear rest */ @@ -190,7 +190,7 @@ rep stosd
/* One entry in the PDP pointing to PD */ - mov eax, offset _pd_startup + mov eax, offset pd_startup or eax, 0x00f stosd /* clear rest */ @@ -268,7 +268,7 @@ mov eax, 0x00a0 // Set PAE and PGE: 10100000b mov cr4, eax
- mov edx, offset _pml4_startup // Point cr3 at PML4 + mov edx, offset pml4_startup // Point cr3 at PML4 mov cr3, edx
mov ecx, 0xC0000080 // Specify EFER MSR @@ -405,42 +405,42 @@ .long gdt /* Base Address */
-.global _BootDrive -_BootDrive: +.global BootDrive +BootDrive: .long 0
-.global _BootPartition -_BootPartition: +.global BootPartition +BootPartition: .long 0
-.global _NotAnX64Processor -_NotAnX64Processor: +.global NotAnX64Processor +NotAnX64Processor: .ascii "FreeLoader: No x64-compatible CPU detected! Exiting..." .byte 0x0d, 0x0a, 0
-.global _NoCPUIDSupport -_NoCPUIDSupport: +.global NoCPUIDSupport +NoCPUIDSupport: .ascii "FreeLoader: No CPUID instruction support detected! Exiting..." .byte 0x0d, 0x0a, 0
/////////////////////////// Checkpoint messages /////////////////////////////// -.global _CheckPoint0 -_CheckPoint0: +.global CheckPoint0 +CheckPoint0: .ascii "Starting FreeLoader..." .byte 0x0d, 0x0a, 0 -.global _CheckPoint1 -_CheckPoint1: +.global CheckPoint1 +CheckPoint1: .ascii "FreeLoader[16-bit]: building page tables..." .byte 0x0d, 0x0a, 0 -.global _CheckPoint2 -_CheckPoint2: +.global CheckPoint2 +CheckPoint2: .ascii "FreeLoader[16-bit]: checking CPU for x64 long mode..." .byte 0x0d, 0x0a, 0
-.global _CheckPoint3 -_CheckPoint3: +.global CheckPoint3 +CheckPoint3: .ascii "FreeLoader: Switching to x64 long mode..." .byte 0x0d, 0x0a, 0
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/boot.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/boot.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/boot.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -24,14 +24,14 @@ #include <arch.h>
-EXTERN(_ChainLoadBiosBootSectorCode) +EXTERN(ChainLoadBiosBootSectorCode) .code64
call x86_64_SwitchToReal .code16
/* Set the boot drive */ - mov dl, _BootDrive + mov dl, BootDrive
/* Load segment registers */ cli @@ -46,7 +46,7 @@ // ljmpl $0x0000,$0x7C00 jmp 0x7c00:0x0000
-EXTERN(_SoftReboot) +EXTERN(SoftReboot) .code64
call x86_64_SwitchToReal
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/drvmap.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/drvmap.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/drvmap.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -24,7 +24,7 @@ #include <arch.h>
-EXTERN(_DriveMapInt13HandlerStart) +EXTERN(DriveMapInt13HandlerStart) Int13Handler:
pushw %bp @@ -82,7 +82,7 @@
/* Call old int 13h handler with new drive number */ .byte 0x9a /* lcall */ -EXTERN(_DriveMapOldInt13HandlerAddress) +EXTERN(DriveMapOldInt13HandlerAddress) .word 0 .word 0
@@ -105,7 +105,7 @@ PassedInDriveNumber: .byte 0
-EXTERN(_DriveMapInt13HandlerMapList) +EXTERN(DriveMapInt13HandlerMapList) Int13HandlerMapCount: .byte 0
@@ -129,4 +129,4 @@ Int13HandlerDriveNew4: .byte 0
-EXTERN(_DriveMapInt13HandlerEnd) +EXTERN(DriveMapInt13HandlerEnd)
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386cpu.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386cpu.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386cpu.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -33,7 +33,7 @@ * 0x00000400: Found 80486 CPU without CPUID support */
-EXTERN(_CpuidSupported) +EXTERN(CpuidSupported) .code32
pushl %ecx /* save ECX */ @@ -80,7 +80,7 @@ * VOID GetCpuid(U32 Level, U32 *eax, U32 *ebx, U32 *ecx, U32 *edx); */
-EXTERN(_GetCpuid) +EXTERN(GetCpuid) .code32
pushl %ebp @@ -123,7 +123,7 @@ * U64 RDTSC(VOID); */
-EXTERN(_RDTSC) +EXTERN(RDTSC) .code32 rdtsc ret
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386pnp.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386pnp.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386pnp.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -35,7 +35,7 @@ _pnp_bios_data_segment: .word 0
-EXTERN(_PnpBiosSupported) +EXTERN(PnpBiosSupported) .code64
push rdi @@ -113,7 +113,7 @@ _pnp_node_count: .word 0
-EXTERN(_PnpBiosGetDeviceNodeCount) +EXTERN(PnpBiosGetDeviceNodeCount) .code64
push rbp @@ -182,7 +182,7 @@ _pnp_node_number: .byte 0
-EXTERN(_PnpBiosGetDeviceNode) +EXTERN(PnpBiosGetDeviceNode) .code64
push rbp
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386trap.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386trap.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/i386trap.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -273,7 +273,7 @@ SAVE_CPU_REGS
pushl $SCREEN_ATTR - call _MachVideoClearScreen + call MachVideoClearScreen add $4,%esp
movl $i386ExceptionHandlerText,%esi @@ -485,7 +485,7 @@ pushl $SCREEN_ATTR andl $0xff,%eax pushl %eax - call _MachVideoPutChar + call MachVideoPutChar addl $16,%esp
ret
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/int386.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/int386.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/int386.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -63,7 +63,7 @@ /* * int Int386(int ivec, REGS* in, REGS* out); */ -EXTERN(_Int386) +EXTERN(Int386) .code64
/* Get the function parameters */
Modified: branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/mb.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/boot/f... ============================================================================== --- branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/mb.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/boot/freeldr/freeldr/arch/amd64/mb.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -29,35 +29,35 @@ * This boots the kernel */ .code64 - .globl _PageDirectoryStart + .globl PageDirectoryStart
- .globl _pml4_startup - .globl _pdp_startup - .globl _pd_startup + .globl pml4_startup + .globl pdp_startup + .globl pd_startup
- .globl _PageDirectoryEnd + .globl PageDirectoryEnd
// // Boot information structure //
-EXTERN(_reactos_memory_map_descriptor_size) +EXTERN(reactos_memory_map_descriptor_size) .long 0
-EXTERN(_reactos_memory_map) +EXTERN(reactos_memory_map) .rept (32 * /*sizeof(memory_map_t)*/24) .byte 0 .endr
.bss -_PageDirectoryStart: -_pml4_startup: +PageDirectoryStart: +pml4_startup: .fill 4096, 1, 0
-_pdp_startup: +pdp_startup: .fill 4096, 1, 0
-_pd_startup: +pd_startup: .fill 4096, 1, 0
-_PageDirectoryEnd: +PageDirectoryEnd:
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/irq.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/irq.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/irq.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -7,65 +7,40 @@
/* INCLUDES ******************************************************************/
-#include <asm.h> -#include <internal/i386/asmmacro.S> -.intel_syntax noprefix - -.macro UNIMPLEMENTED func - jmp 2f -1: - .ascii "Sorry, asm function " - .ascii func - .ascii " is unimplemented!\n\0" -2: - movabs rcx, offset 1b - call _DbgPrint - ret -.endm - - - -/* GLOBALS *******************************************************************/ - +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
/* FUNCTIONS *****************************************************************/
-.global _HalEnableInterrupt -.func _HalEnableInterrupt -_HalEnableInterrupt: - UNIMPLEMENTED "HalEnableInterrupt" -.endfunc +PUBLIC HalEnableInterrupt +HalEnableInterrupt: + UNIMPLEMENTED HalEnableInterrupt + ret
-.global _HalDisableInterrupt -.func _HalDisableInterrupt -_HalDisableInterrupt: - UNIMPLEMENTED "HalDisableInterrupt" -.endfunc +PUBLIC HalDisableInterrupt +HalDisableInterrupt: + UNIMPLEMENTED HalDisableInterrupt + ret
-.global _HalRequestSoftwareInterrupt -.func _HalRequestSoftwareInterrupt -_HalRequestSoftwareInterrupt: - UNIMPLEMENTED "HalRequestSoftwareInterrupt" -.endfunc +PUBLIC HalRequestSoftwareInterrupt +HalRequestSoftwareInterrupt: + UNIMPLEMENTED HalRequestSoftwareInterrupt + ret
-.global _HalSendSoftwareInterrupt -.func _HalSendSoftwareInterrupt -_HalSendSoftwareInterrupt: - UNIMPLEMENTED "HalSendSoftwareInterrupt" -.endfunc +PUBLIC HalSendSoftwareInterrupt +HalSendSoftwareInterrupt: + UNIMPLEMENTED HalSendSoftwareInterrupt + ret
-.global _HalEndSystemInterrupt -.func _HalEndSystemInterrupt -_HalEndSystemInterrupt: - UNIMPLEMENTED "HalEndSystemInterrupt" -.endfunc +PUBLIC HalEndSystemInterrupt +HalEndSystemInterrupt: + UNIMPLEMENTED HalEndSystemInterrupt + ret
- -.globl _HalClearSoftwareInterrupt -.func _HalClearSoftwareInterrupt -_HalClearSoftwareInterrupt: - UNIMPLEMENTED "HalClearSoftwareInterrupt" +PUBLIC HalClearSoftwareInterrupt +HalClearSoftwareInterrupt: + UNIMPLEMENTED HalClearSoftwareInterrupt
/* Get IRR mask */ mov eax, 1 @@ -75,11 +50,8 @@ /* Set IRR */ // and gs:[KPCR_IRR], eax ret -.endfunc
-.globl _HalBeginSystemInterrupt -.func _HalBeginSystemInterrupt -_HalBeginSystemInterrupt: - UNIMPLEMENTED "HalBeginSystemInterrupt" -.endfunc - +PUBLIC HalBeginSystemInterrupt +HalBeginSystemInterrupt: + UNIMPLEMENTED HalBeginSystemInterrupt + ret
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/systimer.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/systimer.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/generic/amd64/systimer.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -7,8 +7,8 @@
/* INCLUDES ******************************************************************/
-#include <asm.h> -#include <ndk/amd64/asmmacro.S> +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
/* GLOBALS *******************************************************************/
@@ -24,22 +24,16 @@ .text .code64
-.global _HalpCalibrateStallExecution@0 -.func HalpCalibrateStallExecution@0 -_HalpCalibrateStallExecution@0: - -.endfunc - -.globl _HalpProfileInterrupt -.func HalpProfileInterrupt -_HalpProfileInterrupt: - -.endfunc +PUBLIC HalpCalibrateStallExecution@0 +HalpCalibrateStallExecution@0:
-.globl _KeStallExecutionProcessor -.func KeStallExecutionProcessor -_KeStallExecutionProcessor: +PUBLIC HalpProfileInterrupt +HalpProfileInterrupt: + + +PUBLIC KeStallExecutionProcessor +KeStallExecutionProcessor:
/* Get the number of microseconds required */ jecxz Done @@ -65,12 +59,10 @@ Done: /* Return */ ret 4 -.endfunc
-.globl _HalpQuery8254Counter -.func HalpQuery8254Counter -_HalpQuery8254Counter: +PUBLIC HalpQuery8254Counter +HalpQuery8254Counter:
/* Save EFLAGS and disable interrupts */ pushfq @@ -92,12 +84,9 @@ mov eax, ecx popfq ret -.endfunc
-.globl _HalpClockInterrupt -.func HalpClockInterrupt -_HalpClockInterrupt: +PUBLIC HalpClockInterrupt +HalpClockInterrupt: UNIMPLEMENTED _HalpClockInterrupt iret -.endfunc
Modified: branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/mps.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/ha... ============================================================================== --- branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/mps.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/hal/halx86/mp/amd64/mps.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,84 +8,85 @@
/* INCLUDES ******************************************************************/
-#include <ndk/asm.h> +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
/* FUNCTIONS *****************************************************************/
#define BEFORE \ cld; \ - pushq %rax; \ - pushq %rbx; \ - pushq %rcx; \ - pushq %rdx; \ - pushq %rsi; \ - pushq %rdi; \ - pushq %fs; \ - pushq %gs; \ + push rax; \ + push rbx; \ + push rcx; \ + push rdx; \ + push rsi; \ + push rdi; \ + push fs; \ + push gs; \
#define AFTER \ - popq %gs; \ - popq %fs; \ - popq %rdi; \ - popq %rsi; \ - popq %rdx; \ - popq %rcx; \ - popq %rbx; \ - popq %rax; \ + pop gs; \ + pop fs; \ + pop rdi; \ + pop rsi; \ + pop rdx; \ + pop rcx; \ + pop rbx; \ + pop rax; \
#ifdef CONFIG_SMP -.global _MpsIpiInterrupt -_MpsIpiInterrupt: +PUBLIC MpsIpiInterrupt +MpsIpiInterrupt: /* Save registers */ BEFORE
/* Call the C handler */ - call _MpsIpiHandler + call MpsIpiHandler
/* Return to the caller */ AFTER iret #endif
-.globl _MpsErrorInterrupt -_MpsErrorInterrupt: +PUBLIC MpsErrorInterrupt +MpsErrorInterrupt: /* Save registers */ BEFORE
/* Call the C handler */ - call _MpsErrorHandler + call MpsErrorHandler
/* Return to the caller */ AFTER iret
-.globl _MpsSpuriousInterrupt -_MpsSpuriousInterrupt: +PUBLIC MpsSpuriousInterrupt +MpsSpuriousInterrupt: /* Save registers */ BEFORE
/* Call the C handler */ - call _MpsSpuriousHandler + call MpsSpuriousHandler
/* Return to the caller */ AFTER iret
-.global _MpsTimerInterrupt -_MpsTimerInterrupt: +PUBLIC MpsTimerInterrupt +MpsTimerInterrupt: /* Save registers */ BEFORE
- movl $0xef,%ebx - movl $0xceafbeef,%eax - pushq %rax - pushq %rsp - pushq %rbx - call _MpsTimerHandler - popq %rax - popq %rax - popq %rax + mov ebx, 0xef + mov eax, 0xceafbeef + push rax + push rsp + push rbx + call MpsTimerHandler + pop rax + pop rax + pop rax
/* Return to the caller */ AFTER
Modified: branches/ros-amd64-bringup/reactos/include/reactos/asm.h URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/includ... ============================================================================== --- branches/ros-amd64-bringup/reactos/include/reactos/asm.h [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/include/reactos/asm.h [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -24,8 +24,9 @@ #define MACRO(name, ...) name MACRO __VA_ARGS__
/* To avoid reverse syntax we provide a new macro .PROC, replacing PROC... */ -.PROC MACRO namex - namex PROC FRAME +.PROC MACRO name + name PROC FRAME + _name: ENDM
/* ... and .ENDP, replacing ENDP */ @@ -41,6 +42,16 @@ /* MASM doesn't have an ASCIZ macro */ .ASCIZ MACRO text DB text, 0 +ENDM + +.text MACRO +ENDM + +.code64 MACRO + .code +ENDM + +UNIMPLEMENTED MACRO name ENDM
/* We need this to distinguish repeat from macros */ @@ -79,7 +90,9 @@ .endm
/* MASM compatible PUBLIC */ -#define PUBLIC .global +.macro PUBLIC symbol + .global \symbol +.endm
/* MASM compatible ALIGN */ #define ALIGN .align @@ -148,7 +161,7 @@ lea rdx, 1b[rip] lea r8, 2b[rip] mov r9, \line - call _DbgPrint + call DbgPrint add rsp, 0x20 .endm #define UNIMPLEMENTED UNIMPLEMENTED2 __FILE__, __LINE__,
Modified: branches/ros-amd64-bringup/reactos/lib/drivers/oskittcp/include/freebsd/src/sys/sys/kernel.h URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/dr... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/drivers/oskittcp/include/freebsd/src/sys/sys/kernel.h [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/drivers/oskittcp/include/freebsd/src/sys/sys/kernel.h [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -83,8 +83,13 @@ #ifdef _MSC_VER #define MAKE_SET(set, sym, type) #else +#if defined(_M_AMD64) +#define MAKE_SET(set, sym, type) \ + asm(".stabs "" #set "", " #type ", 0, 0, " #sym) +#else #define MAKE_SET(set, sym, type) \ asm(".stabs "_" #set "", " #type ", 0, 0, _" #sym) +#endif #endif #define TEXT_SET(set, sym) MAKE_SET(set, sym, 23) #define DATA_SET(set, sym) MAKE_SET(set, sym, 25)
Modified: branches/ros-amd64-bringup/reactos/lib/rtl/amd64/debug_asm.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/rt... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/rtl/amd64/debug_asm.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/rtl/amd64/debug_asm.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -3,54 +3,47 @@ * PROJECT: ReactOS Run-Time Library * PURPOSE: Debug Routines * FILE: lib/rtl/i386/debug.S - * PROGRAMER: Alex Ionescu (alex@relsoft.net) + * PROGRAMER: Timo Kreuzer (timo.kreuzer@reactos.org) */
-.intel_syntax noprefix +#include <reactos/asm.h>
/* GLOBALS ****************************************************************/
-.globl _DbgBreakPoint -.globl _DbgBreakPointWithStatus -.globl _DbgUserBreakPoint -.globl _DebugService -.globl _DebugService2 -.globl _DbgBreakPointNoBugCheck -.globl _RtlpBreakWithStatusInstruction +PUBLIC DbgBreakPoint +PUBLIC DbgBreakPointWithStatus +PUBLIC DbgUserBreakPoint +PUBLIC DebugService +PUBLIC DebugService2 +PUBLIC DbgBreakPointNoBugCheck +PUBLIC RtlpBreakWithStatusInstruction
/* FUNCTIONS ***************************************************************/
-.func DbgBreakPointNoBugCheck -_DbgBreakPointNoBugCheck: +.code64 + +DbgBreakPointNoBugCheck: int 3 ret -.endfunc
-.func DbgBreakPoint -_DbgBreakPoint: -_DbgUserBreakPoint: +DbgBreakPoint: +DbgUserBreakPoint: int 3 ret -.endfunc
-.func DbgBreakPointWithStatus -_DbgBreakPointWithStatus: +DbgBreakPointWithStatus: mov eax, ecx - -_RtlpBreakWithStatusInstruction: +RtlpBreakWithStatusInstruction: int 3 ret -.endfunc
-.func DebugService2 -_DebugService2: +DebugService2: ret /* Call the interrupt */ // mov eax, [rbp+8] // int 0x2D // int 3
-.endfunc
/****************************************************************************** * NTSTATUS NTAPI DebugService( @@ -60,8 +53,7 @@ * IN PVOID Argument1, // <r9> = [rsp + 32] * IN PVOID Argument2); // [rsp + 40] */ -.func DebugService -_DebugService: +DebugService:
/* Prepare registers for interrupt */ mov eax, ecx // Service @@ -71,9 +63,10 @@ mov r9, [rsp + 40] // Argument2
/* Call the Interrupt */ - int 0x2D + int HEX(2D) int 3
/* Return */ ret -.endfunc + +END
Modified: branches/ros-amd64-bringup/reactos/lib/rtl/amd64/except_asm.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/rt... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/rtl/amd64/except_asm.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/rtl/amd64/except_asm.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,24 +8,25 @@
/* INCLUDES ******************************************************************/
-#include <ndk/asm.h> -.intel_syntax noprefix +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
/* FUNCTIONS *****************************************************************/ + +.code64
/* * VOID NTAPI * RtlCaptureContext( * PCONTEXT ContextRecord); <rcx> */ -.func RtlCaptureContext -.global _RtlCaptureContext -_RtlCaptureContext: - .cfi_startproc +PUBLIC RtlCaptureContext +.PROC RtlCaptureContext
/* Push rflags */ pushfq - .cfi_adjust_cfa_offset 8 + .ALLOCSTACK 8 + .ENDPROLOG
/* Save the basic register context */ mov [rcx + CONTEXT_Rax], rax @@ -47,7 +48,7 @@ mov [rcx + CONTEXT_R9], r9
/* Load former stack pointer in rax */ - lea rax, [rsp + 0x10] + lea rax, [rsp + 16]
mov [rcx + CONTEXT_R10], r10 mov [rcx + CONTEXT_R11], r11 @@ -95,6 +96,8 @@ /* Cleanup stack and return */ add rsp, 8 ret - .cfi_endproc -.endfunc +.ENDP RtlCaptureContext
+END + +
Modified: branches/ros-amd64-bringup/reactos/lib/rtl/amd64/rtlmem.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/rt... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/rtl/amd64/rtlmem.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/rtl/amd64/rtlmem.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,10 +8,12 @@
/* INCLUDES ******************************************************************/
-#include <ndk/amd64/asmmacro.S> +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
/* FUNCTIONS *****************************************************************/ -.intel_syntax noprefix + +.code64
/* SIZE_T * RtlCompareMemory( @@ -27,6 +29,7 @@ .pushreg rsi push rdi .pushreg rdi + .ENDPROLOG
/* Setup registers for compare */ mov rsi, rcx @@ -38,41 +41,48 @@ /* Get number of qwords */ mov rcx, r8 shr rcx, 3 - jz 2f + jz RtlCompareMemory2
/* Compare qwords */ repe cmpsq - jnz 4f + jnz RtlCompareMemory4
-2: /* Compare rest */ +RtlCompareMemory2: + /* Compare rest */ mov rcx, r8 and rcx, 7 - jz 3f + jz RtlCompareMemory3
repe cmpsb - jnz 5f + jnz RtlCompareMemory5
-3: /* All equal */ +RtlCompareMemory3: + /* All equal */ /* Return the full count */ mov rax, rcx - jmp 6f + jmp RtlCompareMemory6
-4: /* Not equal after comparing qwords */ +RtlCompareMemory4: + /* Not equal after comparing qwords */ /* Compare the last qword */ sub rsi, 8 sub rdi, 8 mov rcx, 8 repe cmpsb
-5: /* Not equal after comparing bytes */ +RtlCompareMemory5: + /* Not equal after comparing bytes */ /* Return difference */ sub rdi, rdx dec rdi mov rax, rdi
-6: /* Cleanup and return */ +RtlCompareMemory6: + /* Cleanup and return */ pop rdi pop rsi ret -.endproc +.endp RtlCompareMemory
+END +
Modified: branches/ros-amd64-bringup/reactos/lib/rtl/amd64/slist.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/rt... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/rtl/amd64/slist.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/rtl/amd64/slist.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -6,9 +6,8 @@ * PROGRAMMERS: Timo Kreuzer */
-#include <ndk/asm.h> -#include <ndk/amd64/asmmacro.S> -.intel_syntax noprefix +#include <reactos/asm.h> +#include <ndk/amd64/asm.h>
#define SLIST8A_DEPTH_MASK 0x000000000000FFFF #define SLIST8A_DEPTH_INC 0x0000000000000001 @@ -32,15 +31,15 @@
/* FUNCTIONS ****************************************************************/
-.global _ExpInterlockedPopEntrySList -.global _ExpInterlockedPopEntrySListResume -.global _ExpInterlockedPopEntrySListFault -.global _ExpInterlockedPopEntrySListEnd -.global _ExpInterlockedPopEntrySListResume16 -.global _ExpInterlockedPopEntrySListFault16 -.global _ExpInterlockedPopEntrySListEnd16 -.global _ExpInterlockedPushEntrySList -.global _ExpInterlockedFlushSList +.global ExpInterlockedPopEntrySList +.global ExpInterlockedPopEntrySListResume +.global ExpInterlockedPopEntrySListFault +.global ExpInterlockedPopEntrySListEnd +.global ExpInterlockedPopEntrySListResume16 +.global ExpInterlockedPopEntrySListFault16 +.global ExpInterlockedPopEntrySListEnd16 +.global ExpInterlockedPushEntrySList +.global ExpInterlockedFlushSList
/* PSLIST_ENTRY * NTAPI @@ -48,7 +47,7 @@ * IN PSLIST_HEADER ListHead); */ .proc RtlInterlockedPopEntrySList -_ExpInterlockedPopEntrySList: +ExpInterlockedPopEntrySList:
/* Load ListHead->Region into rdx */ mov rdx, [rcx + 8] @@ -58,16 +57,16 @@
/* Check what kind of header this is */ test rdx, SLIST8B_HEADERTYPE_MASK - jnz _RtlInterlockedPopEntrySList16 + jnz RtlInterlockedPopEntrySList16
/* We have an 8 byte header */
-_ExpInterlockedPopEntrySListResume: +ExpInterlockedPopEntrySListResume:
/* Check if ListHead->NextEntry is NULL */ mov r9, rax and r9, SLIST8A_NEXTENTRY_MASK - jz _RtlInterlockedPopEntrySListEmpty + jz RtlInterlockedPopEntrySListEmpty
/* Copy Depth and Sequence number and adjust Depth */ lea r8, [rax - SLIST8A_DEPTH_INC] @@ -83,7 +82,7 @@ /* Combine to new pointer in rdx */ or rdx, r9
-_ExpInterlockedPopEntrySListFault: +ExpInterlockedPopEntrySListFault:
/* Load the next NextEntry pointer to r9 */ mov r9, [rdx] @@ -94,13 +93,13 @@ /* Combine into r8 */ or r8, r9
-_ExpInterlockedPopEntrySListEnd: +ExpInterlockedPopEntrySListEnd:
/* If [rcx] equals rax, exchange it with r8 */ lock cmpxchg [rcx], r8
/* If not equal, retry with rax, being the content of [rcx] now */ - jnz _ExpInterlockedPopEntrySListResume + jnz ExpInterlockedPopEntrySListResume
/* Shift the pointer bits in place */ and rax, SLIST8A_NEXTENTRY_MASK @@ -114,11 +113,11 @@ or rax, rdx ret
-_RtlInterlockedPopEntrySListEmpty: +RtlInterlockedPopEntrySListEmpty: xor rax, rax ret
-_RtlInterlockedPopEntrySList16: +RtlInterlockedPopEntrySList16: /* This is a 16 byte header */
/* Save rbx */ @@ -127,14 +126,14 @@ /* Copy rcx to r8, as we need rcx for the exchange */ mov r8, rcx
-_ExpInterlockedPopEntrySListResume16: +ExpInterlockedPopEntrySListResume16:
/* Check if ListHead->NextEntry is NULL */ mov r9, rdx and r9, SLIST16B_NEXTENTY_MASK - jz _RtlInterlockedPopEntrySListEmpty16 - -_ExpInterlockedPopEntrySListFault16: + jz RtlInterlockedPopEntrySListEmpty16 + +ExpInterlockedPopEntrySListFault16:
/* Get next pointer */ mov rcx, [r9] @@ -145,13 +144,13 @@ /* Copy Depth and Sequence number and adjust Depth */ lea rbx, [rax - SLIST16A_DEPTH_INC]
-_ExpInterlockedPopEntrySListEnd16: +ExpInterlockedPopEntrySListEnd16:
/* If [r8] equals rdx:rax, exchange it with rcx:rbx */ lock cmpxchg16b [r8]
/* If not equal, retry with rdx:rax, being the content of [r8] now */ - jnz _ExpInterlockedPopEntrySListResume16 + jnz ExpInterlockedPopEntrySListResume16
/* Copy the old NextEntry pointer to rax */ mov rax, rdx @@ -161,12 +160,12 @@ pop rbx ret
-_RtlInterlockedPopEntrySListEmpty16: +RtlInterlockedPopEntrySListEmpty16: xor rax, rax pop rbx ret
-.endproc +.endp RtlInterlockedPopEntrySList
/* PSLIST_ENTRY @@ -176,7 +175,7 @@ * IN PSLIST_ENTRY ListEntry); */ .proc RtlInterlockedPushEntrySList -_ExpInterlockedPushEntrySList: +ExpInterlockedPushEntrySList:
/* Load ListHead->Alignment into rax */ mov rax, [rcx] @@ -186,16 +185,16 @@
/* Check what kind of header this is */ test r9, SLIST8B_HEADERTYPE_MASK - jnz _RtlInterlockedPushEntrySList16 + jnz RtlInterlockedPushEntrySList16
/* We have an 8 byte header */
-_RtlInterlockedPushEntrySListLoop: +RtlInterlockedPushEntrySListLoop:
/* Get ListHead->NextEntry */ mov r8, rax and r8, SLIST8A_NEXTENTRY_MASK - jz _RtlInterlockedPushEntrySListEmpty + jz RtlInterlockedPushEntrySListEmpty
/* Shift the NextEntry pointer */ shr r8, SLIST8A_NEXTENTRY_SHIFT @@ -207,7 +206,7 @@ /* Combine to new pointer and save as ListEntry->NextEntry */ or r8, r9
-_RtlInterlockedPushEntrySListEmpty: +RtlInterlockedPushEntrySListEmpty: /* Store the NextEntry pointer in the new ListEntry */ mov [rdx], r8
@@ -230,13 +229,13 @@ lock cmpxchg [rcx], r8
/* If not equal, retry with rax, being the content of [rcx] now */ - jnz _RtlInterlockedPushEntrySListLoop + jnz RtlInterlockedPushEntrySListLoop
/* Return the old NextEntry pointer */ mov rax, r9 ret
-_RtlInterlockedPushEntrySList16: +RtlInterlockedPushEntrySList16: /* This is a 16 byte header */
/* Save rbx */ @@ -252,7 +251,7 @@
mov rdx, [r8 + 8]
-_RtlInterlockedPushEntrySListLoop16: +RtlInterlockedPushEntrySListLoop16:
/* Move ListHead->NextEntry to rbx */ mov rbx, rdx @@ -268,7 +267,7 @@ lock cmpxchg16b [r8]
/* If not equal, retry with rdx:rax, being the content of [r8] now */ - jnz _RtlInterlockedPushEntrySListLoop16 + jnz RtlInterlockedPushEntrySListLoop16
/* Copy the old NextEntry pointer to rax */ mov rax, rdx @@ -278,7 +277,7 @@ pop rbx ret
-.endproc +.endp RtlInterlockedPushEntrySList
/* PSLIST_ENTRY * NTAPI @@ -286,18 +285,18 @@ * IN PSINGLE_LIST_ENTRY ListHead); */ .proc RtlInterlockedFlushSList -_ExpInterlockedFlushSList: +ExpInterlockedFlushSList:
/* Load ListHead->Region into rdx */ mov rax, [rcx + 8]
/* Check what kind of header this is */ test rax, SLIST8B_HEADERTYPE_MASK - jnz _RtlInterlockedFlushSList16 + jnz RtlInterlockedFlushSList16
/* We have an 8 byte header */
-_RtlInterlockedFlushSListLoop: +RtlInterlockedFlushSListLoop:
/* Zero ListHead->Alignment */ xor r8, r8 @@ -306,7 +305,7 @@ lock cmpxchg [rcx], r8
/* If not equal, retry with rax, being the content of [rcx] now */ - jnz _RtlInterlockedFlushSListLoop + jnz RtlInterlockedFlushSListLoop
/* Use rcx as pointer template */ mov rdx, ~SLIST8_POINTER_MASK @@ -316,7 +315,7 @@ or rax, rdx ret
-_RtlInterlockedFlushSList16: +RtlInterlockedFlushSList16: /* We have a 16 byte header */ push rbx
@@ -324,13 +323,13 @@ xor rbx, rbx mov rcx, 0x3
-_RtlInterlockedFlushSListLoop16: +RtlInterlockedFlushSListLoop16:
/* If [r8] equals rdx:rax, exchange it with rcx:rbx */ lock cmpxchg16b [r8]
/* If not equal, retry with rdx:rax, being the content of [r8] now */ - jnz _RtlInterlockedFlushSListLoop16 + jnz RtlInterlockedFlushSListLoop16
/* Copy the old NextEntry pointer to rax */ mov rax, rdx @@ -340,4 +339,4 @@ pop rbx ret
-.endproc +.endp RtlInterlockedFlushSList
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/except/amd64/chkstk_asm.s URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/except/amd64/chkstk_asm.s [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/except/amd64/chkstk_asm.s [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,8 +8,7 @@
/* INCLUDES ******************************************************************/
-#include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S> +#include <reactos/asm.h>
.intel_syntax noprefix
@@ -21,11 +20,11 @@ .proc _chkstk UNIMPLEMENTED chkstk ret -.endproc +.endp
.proc _alloca_probe UNIMPLEMENTED alloca_probe ret -.endproc +.endp
/* EOF */
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/alldiv.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/alldiv.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/alldiv.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,21 +8,21 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S> - -.intel_syntax noprefix
/* DATA *********************************************************************/
- .globl __fltused -__fltused: +PUBLIC _fltused +_fltused: .long 0x9875
/* FUNCTIONS ****************************************************************/ + +.code64
.proc alldiv UNIMPLEMENTED alldiv ret
-.endproc +.endp alldiv
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,14 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc atan +PUBLIC atan +atan: UNIMPLEMENTED atan ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan2.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan2.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/atan2.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,14 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc atan2 +PUBLIC atan2 +atan2: UNIMPLEMENTED atan2 ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceil.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceil.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceil.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,15 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc ceil +PUBLIC ceil +ceil: UNIMPLEMENTED ceil ret
-.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceilf.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceilf.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ceilf.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,13 +8,15 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc ceilf +PUBLIC ceilf +ceilf: /* Put parameter on the stack */ movss [rsp - 0x10], xmm0 fld dword ptr [rsp] @@ -36,5 +38,3 @@ fstp dword ptr [rsp - 0x10] movss xmm0, [rsp - 0x10] ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/exp.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/exp.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/exp.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,15 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc exp +PUBLIC exp +exp: UNIMPLEMENTED exp ret
-.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fabs.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fabs.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fabs.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,15 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc fabs +PUBLIC fabs +fabs: UNIMPLEMENTED fabs ret
-.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floor.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floor.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floor.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,14 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc floor +PUBLIC floor +floor: UNIMPLEMENTED floor ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floorf.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floorf.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/floorf.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,13 +8,15 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* FUNCTIONS ****************************************************************/
+.code64
-.proc floorf +PUBLIC floorf +floorf: /* Put parameter on the stack */ movss [rsp - 0x10], xmm0 fld dword ptr [rsp] @@ -36,5 +38,3 @@ fstp dword ptr [rsp - 0x10] movss xmm0, [rsp - 0x10] ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmod.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmod.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmod.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc fmod +PUBLIC fmod +fmod: UNIMPLEMENTED fmod ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmodf.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmodf.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/fmodf.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc fmodf +PUBLIC fmodf +fmodf: UNIMPLEMENTED fmodf ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ldexp.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ldexp.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/ldexp.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc ldexp +PUBLIC ldexp +ldexp: UNIMPLEMENTED ldexp ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc log +PUBLIC log +log: UNIMPLEMENTED log ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log10.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log10.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/log10.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,13 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc log10 +PUBLIC log10 +log10: UNIMPLEMENTED log10 ret
-.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/pow.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/pow.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/pow.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,13 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc pow +PUBLIC pow +pow: UNIMPLEMENTED pow ret
-.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrt.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrt.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrt.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc sqrt +PUBLIC sqrt +sqrt: UNIMPLEMENTED sqrt ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrtf.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrtf.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/sqrtf.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,13 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc sqrtf +PUBLIC sqrtf +sqrtf: sqrtss xmm0, xmm0 ret -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/tan.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/tan.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/math/amd64/tan.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,14 +8,12 @@
/* INCLUDES ******************************************************************/
+#include <reactos/asm.h> #include <ndk/amd64/asm.h> -#include <ndk/amd64/asmmacro.S>
-.intel_syntax noprefix +/* DATA *********************************************************************/
- -.proc tan +PUBLIC tan +tan: UNIMPLEMENTED tan ret - -.endproc
Modified: branches/ros-amd64-bringup/reactos/lib/sdk/crt/setjmp/amd64/setjmp.s URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/lib/sd... ============================================================================== --- branches/ros-amd64-bringup/reactos/lib/sdk/crt/setjmp/amd64/setjmp.s [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/lib/sdk/crt/setjmp/amd64/setjmp.s [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -44,8 +44,8 @@ * Returns: 0 * Notes: Sets up the jmp_buf */ -PUBLIC __setjmp -.proc __setjmp +PUBLIC _setjmp +.proc _setjmp /* Load rsp as it was before the call into rax */ lea rax, [rsp + 8] /* Load return address into r8 */ @@ -73,7 +73,7 @@ movdqa [rcx + JUMP_BUFFER_Xmm15], xmm15 xor rax, rax ret -.endp +.endp _setjmp
/* * int _setjmpex(jmp_buf _Buf,void *_Ctx); @@ -83,8 +83,8 @@ * Returns: 0 * Notes: Sets up the jmp_buf */ -PUBLIC __setjmpex -.proc __setjmpex +PUBLIC _setjmpex +.proc _setjmpex /* Load rsp as it was before the call into rax */ lea rax, [rsp + 8] /* Load return address into r8 */ @@ -112,7 +112,7 @@ movdqa [rcx + JUMP_BUFFER_Xmm15], xmm15 xor rax, rax ret -.endp +.endp _setjmpex
/* @@ -123,8 +123,8 @@ * Returns: Doesn't return * Notes: Non-local goto */ -PUBLIC _longjmp -.proc _longjmp +PUBLIC longjmp +.proc longjmp
// FIXME: handle frame
@@ -155,4 +155,4 @@ jnz 2f inc rax 2: jmp r8 -.endp +.endp longjmp
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/boot.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntoskr... ============================================================================== --- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/boot.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/boot.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -8,15 +8,16 @@
/* INCLUDES ******************************************************************/
-#include <asm.h> -.intel_syntax noprefix -.code64 +#include <reactos/asm.h> +#include <ndk/amd64/asm.h> +
/* GLOBALS *******************************************************************/
/* FUNCTIONS *****************************************************************/
+.code64 .text
/** @@ -29,9 +30,8 @@ * IN CCHAR Number, <rsp + 0x28> * IN PLOADER_PARAMETER_BLOCK LoaderBlock) <rsp + 0x30> */ -.globl _KiSetupStackAndInitializeKernel -.func KiSetupStackAndInitializeKernel -_KiSetupStackAndInitializeKernel: +PUBLIC KiSetupStackAndInitializeKernel +.PROC KiSetupStackAndInitializeKernel
/* Save current stack */ mov rsi, rsp @@ -53,6 +53,9 @@ movsq movsq
- jmp _KiInitializeKernelAndGotoIdleLoop + jmp KiInitializeKernelAndGotoIdleLoop
-.endfunc +.ENDP KiSetupStackAndInitializeKernel + +END +
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/ctxswitch.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntoskr... ============================================================================== --- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/ctxswitch.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/ctxswitch.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -44,8 +44,8 @@ * *--*/ .func KiThreadStartup -.globl _KiThreadStartup -_KiThreadStartup: +.globl KiThreadStartup +KiThreadStartup:
/* * Clear all the non-volatile registers, so the thread won't be tempted to @@ -85,7 +85,7 @@
/* Exit back to user-mode */ // jmp _KiServiceExit2 -UNIMPLEMENTED "KiThreadStartup->KiServiceExit2" +UNIMPLEMENTED KiThreadStartup->KiServiceExit2
BadThread:
@@ -112,10 +112,10 @@ * Absolutely all registers except ESP can be trampled here for maximum code flexibility. * *--*/ -.globl _KiSwapContextInternal -.func _KiSwapContextInternal, _KiSwapContextInternal -_KiSwapContextInternal: - UNIMPLEMENTED "KiSwapContextInternal" +.globl KiSwapContextInternal +.func KiSwapContextInternal +KiSwapContextInternal: + UNIMPLEMENTED KiSwapContextInternal ret
.endfunc @@ -147,9 +147,9 @@ * another thread switches to IT. * *--*/ -.globl _KiSwapContext -.func _KiSwapContext, _KiSwapContext -_KiSwapContext: +.globl KiSwapContext +.func KiSwapContext +KiSwapContext:
/* Save 10 registers */ sub rsp, 10 * 8 @@ -180,7 +180,7 @@ movzx ecx, byte ptr [edi+KTHREAD_WAIT_IRQL]
/* Do the swap with the registers correctly setup */ - call _KiSwapContextInternal + call KiSwapContextInternal
/* Restore the registers */ mov rbp, [rsp+0]
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/trap.S URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntoskr... ============================================================================== --- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/trap.S [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/trap.S [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -10,20 +10,20 @@ #include <reactos/asm.h> #include <ndk/amd64/asm.h>
-EXTERN _KiDispatchException:PROC -EXTERN _FrLdrDbgPrint:DWORD -EXTERN _KeBugCheckWithTf:PROC -EXTERN _MmAccessFault:PROC -EXTERN _KiSystemFatalException:PROC -EXTERN _KiNpxNotAvailableFaultHandler:PROC -EXTERN _KiGeneralProtectionFaultHandler:PROC -EXTERN _KiXmmExceptionHandler:PROC +EXTERN KiDispatchException:PROC +EXTERN FrLdrDbgPrint:DWORD +EXTERN KeBugCheckWithTf:PROC +EXTERN MmAccessFault:PROC +EXTERN KiSystemFatalException:PROC +EXTERN KiNpxNotAvailableFaultHandler:PROC +EXTERN KiGeneralProtectionFaultHandler:PROC +EXTERN KiXmmExceptionHandler:PROC
/* GLOBALS *******************************************************************/
.data
-PUBLIC _MsgUnimplemented +PUBLIC MsgUnimplemented _MsgUnimplemented: .ascii "WARNING: %s at %s:%d is UNIMPLEMENTED!\n"
@@ -58,7 +58,7 @@ lea rcx, _MsgTrapInfo[rip] lea rdx, 1b[rip] mov r8, [rbp + KTRAP_FRAME_Rip] - call qword ptr _FrLdrDbgPrint[rip] + call qword ptr FrLdrDbgPrint[rip] add rsp, 32 #endif ENDM @@ -263,18 +263,18 @@
ALIGN 8
-PUBLIC _InterruptDispatchTable -_InterruptDispatchTable: +PUBLIC InterruptDispatchTable +InterruptDispatchTable: Vector = 0 REPEAT 256 push Vector - jmp _KiUnexpectedInterrupt + jmp KiUnexpectedInterrupt ALIGN 8 Vector = Vector+1 ENDR
// rbp = TrapFrame, eax = ExceptionCode, edx = NumParams, r9,r10,r11 = params -.PROC _InternalDispatchException +.PROC InternalDispatchException
/* Allocate stack space for EXCEPTION_RECORD and KEXCEPTION_FRAME */ sub rsp, SIZE_EXCEPTION_RECORD + SIZE_KEXCEPTION_FRAME @@ -322,7 +322,7 @@ mov r8, rbp // TrapFrame mov r9b, [r8 + KTRAP_FRAME_PreviousMode] // PreviousMode mov byte ptr [rsp + KEXCEPTION_FRAME_P5], 1 // FirstChance - call _KiDispatchException + call KiDispatchException
/* Restore registers */ mov r12, [rsp + KEXCEPTION_FRAME_R12] @@ -342,13 +342,13 @@
add rsp, SIZE_EXCEPTION_RECORD + SIZE_KEXCEPTION_FRAME ret -.ENDP _InternalDispatchException +.ENDP InternalDispatchException
/* SOFTWARE INTERRUPT SERVICES ***********************************************/
-PUBLIC _KiDivideErrorFault -.PROC _KiDivideErrorFault +PUBLIC KiDivideErrorFault +.PROC KiDivideErrorFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -361,16 +361,16 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiDivideErrorFault - - -PUBLIC _KiDebugTrapOrFault -.PROC _KiDebugTrapOrFault +.ENDP KiDivideErrorFault + + +PUBLIC KiDebugTrapOrFault +.PROC KiDebugTrapOrFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -391,16 +391,16 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiDebugTrapOrFault - - -PUBLIC _KiNmiInterrupt -.PROC _KiNmiInterrupt +.ENDP KiDebugTrapOrFault + + +PUBLIC KiNmiInterrupt +.PROC KiNmiInterrupt /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -411,11 +411,11 @@ /* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiNmiInterrupt - - -PUBLIC _KiBreakpointTrap -.PROC _KiBreakpointTrap +.ENDP KiNmiInterrupt + + +PUBLIC KiBreakpointTrap +.PROC KiBreakpointTrap /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -423,7 +423,7 @@
// lea rcx, _MsgBreakpointTrap[rip] // mov rdx, rsp -// call qword ptr _FrLdrDbgPrint[rip] +// call qword ptr FrLdrDbgPrint[rip]
/* Dispatch the exception */ mov eax, STATUS_BREAKPOINT @@ -431,16 +431,16 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiBreakpointTrap - - -PUBLIC _KiOverflowTrap -.PROC _KiOverflowTrap +.ENDP KiBreakpointTrap + + +PUBLIC KiOverflowTrap +.PROC KiOverflowTrap /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -453,16 +453,16 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiOverflowTrap - - -PUBLIC _KiBoundFault -.PROC _KiBoundFault +.ENDP KiOverflowTrap + + +PUBLIC KiBoundFault +.PROC KiBoundFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -473,7 +473,7 @@ /* Bugcheck */ mov ecx, EXCEPTION_BOUND_CHECK mov rdx, rbp - call _KiSystemFatalException + call KiSystemFatalException
KiBoundFaltUserMode: /* Enable interrupts for user-mode */ @@ -485,16 +485,16 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiBoundFault - - -PUBLIC _KiInvalidOpcodeFault -.PROC _KiInvalidOpcodeFault +.ENDP KiBoundFault + + +PUBLIC KiInvalidOpcodeFault +.PROC KiInvalidOpcodeFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -502,7 +502,7 @@
mov rdx, [rbp + KTRAP_FRAME_Rip] lea rcx, _MsgInvalidOpcodeFault[rip] - call qword ptr _FrLdrDbgPrint[rip] + call qword ptr FrLdrDbgPrint[rip]
/* Enable interrupts */ sti @@ -522,22 +522,22 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
/* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiInvalidOpcodeFault - - -PUBLIC _KiNpxNotAvailableFault -.PROC _KiNpxNotAvailableFault +.ENDP KiInvalidOpcodeFault + + +PUBLIC KiNpxNotAvailableFault +.PROC KiNpxNotAvailableFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
/* Call the C handler */ mov rcx, rbp - call _KiNpxNotAvailableFaultHandler + call KiNpxNotAvailableFaultHandler
/* Check the return status code */ test eax, eax @@ -548,102 +548,102 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
KiNpxNotAvailableFaultExit: /* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiNpxNotAvailableFault - - -PUBLIC _KiDoubleFaultAbort -.PROC _KiDoubleFaultAbort +.ENDP KiNpxNotAvailableFault + + +PUBLIC KiDoubleFaultAbort +.PROC KiDoubleFaultAbort /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
lea rcx, _MsgDoubleFault[rip] mov rdx, [rbp + KTRAP_FRAME_FaultAddress] mov r8, rbp - call qword ptr _FrLdrDbgPrint[rip] + call qword ptr FrLdrDbgPrint[rip]
/* Bugcheck */ mov ecx, 8 // EXCEPTION_DOUBLE_FAULT mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiDoubleFaultAbort - - -PUBLIC _KiNpxSegmentOverrunAbort -.PROC _KiNpxSegmentOverrunAbort + call KiSystemFatalException + + jmp $ +.ENDP KiDoubleFaultAbort + + +PUBLIC KiNpxSegmentOverrunAbort +.PROC KiNpxSegmentOverrunAbort /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
/* Bugcheck */ mov ecx, EXCEPTION_NPX_OVERRUN mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiNpxSegmentOverrunAbort - - -PUBLIC _KiInvalidTssFault -.PROC _KiInvalidTssFault + call KiSystemFatalException + + jmp $ +.ENDP KiNpxSegmentOverrunAbort + + +PUBLIC KiInvalidTssFault +.PROC KiInvalidTssFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
/* Bugcheck */ mov ecx, EXCEPTION_INVALID_TSS mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiInvalidTssFault - - -PUBLIC _KiSegmentNotPresentFault -.PROC _KiSegmentNotPresentFault + call KiSystemFatalException + + jmp $ +.ENDP KiInvalidTssFault + + +PUBLIC KiSegmentNotPresentFault +.PROC KiSegmentNotPresentFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
/* Bugcheck */ mov ecx, EXCEPTION_SEGMENT_NOT_PRESENT mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiSegmentNotPresentFault - - -PUBLIC _KiStackFault -.PROC _KiStackFault + call KiSystemFatalException + + jmp $ +.ENDP KiSegmentNotPresentFault + + +PUBLIC KiStackFault +.PROC KiStackFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
/* Bugcheck */ mov ecx, EXCEPTION_STACK_FAULT mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiStackFault - - -PUBLIC _KiGeneralProtectionFault -.PROC _KiGeneralProtectionFault + call KiSystemFatalException + + jmp $ +.ENDP KiStackFault + + +PUBLIC KiGeneralProtectionFault +.PROC KiGeneralProtectionFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
TRAPINFO KiGeneralProtectionFault mov rdx, [rbp + KTRAP_FRAME_Rip] lea rcx, _MsgGeneralProtFault[rip] - call qword ptr _FrLdrDbgPrint[rip] + call qword ptr FrLdrDbgPrint[rip]
/* Call the C handler */ - call _KiGeneralProtectionFaultHandler + call KiGeneralProtectionFaultHandler
/* Check for success */ test eax, eax @@ -654,7 +654,7 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
KiGpfFatal:
@@ -665,17 +665,17 @@ mov r9, [rbp + KTRAP_FRAME_ErrorCode] // error code sub rsp, 8 mov [rsp + KTRAP_FRAME_P5+8], rbp // trap frame - call _KeBugCheckWithTf + call KeBugCheckWithTf
KiGpfExit: /* Return */ LEAVE_TRAP_FRAME iretq -.ENDP _KiGeneralProtectionFault - - -PUBLIC _KiPageFault -.PROC _KiPageFault +.ENDP KiGeneralProtectionFault + + +PUBLIC KiPageFault +.PROC KiPageFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
@@ -686,7 +686,7 @@ mov rdx, [rbp + KTRAP_FRAME_ErrorCode] mov r8, [rbp + KTRAP_FRAME_Rip] mov r9, [rbp + KTRAP_FRAME_FaultAddress] - call qword ptr _FrLdrDbgPrint[rip] + call qword ptr FrLdrDbgPrint[rip] #endif
/* Save page fault address */ @@ -700,7 +700,7 @@ mov r8b, [rbp + KTRAP_FRAME_SegCs] // Mode and r8b, 1 mov r9, rbp // TrapInformation - call _MmAccessFault + call MmAccessFault
/* Check for success */ test eax, eax @@ -724,7 +724,7 @@ mov r11d, eax // Param3 = Status mov eax, STATUS_IN_PAGE_ERROR // ExceptionCode mov edx, 3 // ParamCount - call _InternalDispatchException + call InternalDispatchException jmp PageFaultReturn
AccessViolation: @@ -734,27 +734,27 @@ SpecialCode: /* Setup a normal page fault exception */ mov edx, 2 // ParamCount - call _InternalDispatchException + call InternalDispatchException
PageFaultReturn: LEAVE_TRAP_FRAME iretq -.ENDP _KiPageFault - - -PUBLIC _KiFloatingErrorFault -.PROC _KiFloatingErrorFault +.ENDP KiPageFault + + +PUBLIC KiFloatingErrorFault +.PROC KiFloatingErrorFault /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
UNIMPLEMENTED KiFloatingErrorFault
jmp $ -.ENDP _KiFloatingErrorFault - - -PUBLIC _KiAlignmentFault -.PROC _KiAlignmentFault +.ENDP KiFloatingErrorFault + + +PUBLIC KiAlignmentFault +.PROC KiAlignmentFault /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
@@ -764,34 +764,34 @@ /* Bugcheck */ mov ecx, EXCEPTION_ALIGNMENT_CHECK mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiAlignmentFault - - -PUBLIC _KiMcheckAbort -.PROC _KiMcheckAbort + call KiSystemFatalException + + jmp $ +.ENDP KiAlignmentFault + + +PUBLIC KiMcheckAbort +.PROC KiMcheckAbort /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
/* Bugcheck */ mov ecx, HEX(12) mov rdx, rbp - call _KiSystemFatalException - - jmp $ -.ENDP _KiMcheckAbort - - -PUBLIC _KiXmmException -.PROC _KiXmmException + call KiSystemFatalException + + jmp $ +.ENDP KiMcheckAbort + + +PUBLIC KiXmmException +.PROC KiXmmException /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
/* Call the C handler */ mov rcx, rbp - call _KiXmmExceptionHandler + call KiXmmExceptionHandler
/* Check for success */ test eax, eax @@ -802,27 +802,27 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
KiXmmExit: LEAVE_TRAP_FRAME iretq -.ENDP _KiXmmException - - -PUBLIC _KiApcInterrupt -.PROC _KiApcInterrupt +.ENDP KiXmmException + + +PUBLIC KiApcInterrupt +.PROC KiApcInterrupt /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
UNIMPLEMENTED KiApcInterrupt
jmp $ -.ENDP _KiApcInterrupt - - -PUBLIC _KiRaiseAssertion -.PROC _KiRaiseAssertion +.ENDP KiApcInterrupt + + +PUBLIC KiRaiseAssertion +.PROC KiRaiseAssertion /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
@@ -835,15 +835,15 @@ mov r9, 0 mov r10, 0 mov r11, 0 - call _InternalDispatchException + call InternalDispatchException
LEAVE_TRAP_FRAME iretq -.ENDP _KiRaiseAssertion - - -PUBLIC _KiDebugServiceTrap -.PROC _KiDebugServiceTrap +.ENDP KiRaiseAssertion + + +PUBLIC KiDebugServiceTrap +.PROC KiDebugServiceTrap /* Push pseudo error code */ ENTER_TRAP_FRAME TRAPFLAG_ALL
@@ -858,37 +858,37 @@ mov r9, [rbp+KTRAP_FRAME_Rax] // Service mov r10, [rbp+KTRAP_FRAME_Rcx] // Buffer mov r11, [rbp+KTRAP_FRAME_Rdx] // Length - call _InternalDispatchException + call InternalDispatchException
LEAVE_TRAP_FRAME; iretq -.ENDP _KiDebugServiceTrap - - -PUBLIC _KiDpcInterrupt -.PROC _KiDpcInterrupt +.ENDP KiDebugServiceTrap + + +PUBLIC KiDpcInterrupt +.PROC KiDpcInterrupt /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
UNIMPLEMENTED KiDpcInterrupt
jmp $ -.ENDP _KiDpcInterrupt - - -PUBLIC _KiIpiInterrupt -.PROC _KiIpiInterrupt +.ENDP KiDpcInterrupt + + +PUBLIC KiIpiInterrupt +.PROC KiIpiInterrupt /* We have an error code */ ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL)
UNIMPLEMENTED KiIpiInterrupt
jmp $ -.ENDP _KiIpiInterrupt - - -PUBLIC _KiUnexpectedInterrupt -.PROC _KiUnexpectedInterrupt +.ENDP KiIpiInterrupt + + +PUBLIC KiUnexpectedInterrupt +.PROC KiUnexpectedInterrupt /* The error code is the vector */ cli ENTER_TRAP_FRAME (TRAPFLAG_HAS_ERRORCODE OR TRAPFLAG_ALL) @@ -900,10 +900,10 @@ mov r9, 0 // The enabled and asserted status bits sub rsp, 8 mov [rbp + KTRAP_FRAME_P5 + 8], rbp // trap frame - call _KeBugCheckWithTf - - jmp $ -.ENDP _KiUnexpectedInterrupt + call KeBugCheckWithTf + + jmp $ +.ENDP KiUnexpectedInterrupt
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/mm/amd64/page.c URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntoskr... ============================================================================== --- branches/ros-amd64-bringup/reactos/ntoskrnl/mm/amd64/page.c [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/ntoskrnl/mm/amd64/page.c [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -13,11 +13,6 @@ #define NDEBUG #include <debug.h>
-#if defined (ALLOC_PRAGMA) -#pragma alloc_text(INIT, MmInitGlobalKernelPageDirectory) -#pragma alloc_text(INIT, MiInitPageDirectoryMap) -#endif - #undef InterlockedExchangePte #define InterlockedExchangePte(pte1, pte2) \ InterlockedExchange64(&pte1->u.Long, pte2.u.Long)
Modified: branches/ros-amd64-bringup/reactos/tools/nci/ncitool.c URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/tools/... ============================================================================== --- branches/ros-amd64-bringup/reactos/tools/nci/ncitool.c [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/tools/nci/ncitool.c [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -103,7 +103,7 @@ " ret $0x%x\n\n"
#define KernelModeStub_amd64 " movl $0x%x, %%eax\n" \ - " call _KiSystemService\n" \ + " call KiSystemService\n" \ " ret $0x%x\n\n"
/* For now, use the usermode stub. We'll optimize later */ @@ -143,7 +143,7 @@ { "i386", 4, KernelModeStub_x86, UserModeStub_x86, ".global _%s@%d\n", "_%s@%d:\n" }, { "amd64", 4, KernelModeStub_amd64, UserModeStub_amd64, - ".global _%s\n", "_%s:\n" }, + ".global %s\n", "%s:\n" }, { "powerpc", 4, KernelModeStub_ppc, UserModeStub_ppc, "\t.globl %s\n", "%s:\n" }, { "mips", 4, KernelModeStub_mips, UserModeStub_mips,
Modified: branches/ros-amd64-bringup/reactos/tools/rbuild/backend/mingw/linkers/ld.mak URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/tools/... ============================================================================== --- branches/ros-amd64-bringup/reactos/tools/rbuild/backend/mingw/linkers/ld.mak [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/tools/rbuild/backend/mingw/linkers/ld.mak [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -6,6 +6,10 @@ LDFLAG_NATIVE:=--subsystem=native
LDFLAG_EXCLUDE_ALL_SYMBOLS=-exclude-all-symbols +DLLTOOL_FLAGS=--kill-at +ifeq ($(ARCH),amd64) + DLLTOOL_FLAGS= --no-leading-underscore +endif
#~ #(module, objs, deps, ldflags, output, def, libs, entry, base) #(module, objs, deps, ldflags, output, def, libs, entry, base, extralibs) @@ -14,15 +18,15 @@ ifneq ($(6),) ${call RBUILD_intermediate_dir,$(5)}$$(SEP)lib${call RBUILD_name,$(5)}.a: $(6) | ${call RBUILD_intermediate_path,$(5)} $$(ECHO_IMPLIB) - $${dlltool} --def $(6) --kill-at --output-lib=$$@ + $${dlltool} --def $(6) $(DLLTOOL_FLAGS) --output-lib=$$@
${call RBUILD_intermediate_dir,$(5)}$$(SEP)lib${call RBUILD_name,$(5)}.delayimp.a: $(6) | ${call RBUILD_intermediate_path,$(5)} $$(ECHO_IMPLIB) - $${dlltool} --def $(6) --kill-at --output-delaylib=$$@ + $${dlltool} --def $(6) $(DLLTOOL_FLAGS) --output-delaylib=$$@
${call RBUILD_intermediate_path_noext,$(5)}.exp: $(6) | ${call RBUILD_intermediate_path,$(5)} $$(ECHO_IMPLIB) - $${dlltool} --def $(6) --kill-at --output-exp=$$@ + $${dlltool} --def $(6) $(DLLTOOL_FLAGS) --output-exp=$$@
$(1)_CLEANFILES+=\ ${call RBUILD_intermediate_dir,$(5)}$$(SEP)lib$(notdir $(5)).a \
Modified: branches/ros-amd64-bringup/reactos/tools/rbuild/module.cpp URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/tools/... ============================================================================== --- branches/ros-amd64-bringup/reactos/tools/rbuild/module.cpp [iso-8859-1] (original) +++ branches/ros-amd64-bringup/reactos/tools/rbuild/module.cpp [iso-8859-1] Thu Feb 4 05:58:09 2010 @@ -1364,7 +1364,7 @@ if (entrypoint == "0" || entrypoint == "0x0") return "0"; - if (Environment::GetArch() != "arm") + if (Environment::GetArch() != "arm" && Environment::GetArch() != "amd64") result = "_";
result += entrypoint;