Improve debuggability by adding .func/.endfunc around functions.
[pintos-anon] / src / threads / switch.S
index 4f0d412c7266e3117d6fa33bdb2e9f598dbb63e8..f58c4a8931a15c8908b8d2264608e1b8ace344d6 100644 (file)
 #### restore the registers.  As part of switching stacks we record the
 #### current stack pointer in CUR's thread structure.
 
-       .intel_syntax noprefix
+.intel_syntax noprefix
 
-.globl switch_threads 
+.globl switch_threads
+.func switch_threads
 switch_threads:
        # Save caller's register state.
        #
@@ -49,8 +50,10 @@ switch_threads:
        pop ebp
        pop ebx
         ret
+.endfunc
 
 .globl switch_entry
+.func switch_entry
 switch_entry:
        # Discard switch_threads() arguments.
        add esp, 8
@@ -63,3 +66,4 @@ switch_entry:
 
        # Start thread proper.
        ret
+.endfunc