Changeset 18e0a6c in mainline for src


Ignore:
Timestamp:
2005-06-09T23:43:45Z (20 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
74df77d
Parents:
d896525
Message:

Implement several assembler functions in gcc's asm notation instead of in .s or .S file.
Gain both better speed and size.

Location:
src
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • src/debug/print.c

    rd896525 r18e0a6c  
    3131#include <synch/spinlock.h>
    3232#include <arch/arg.h>
     33#include <arch/asm.h>
    3334
    3435
  • src/mm/frame.c

    rd896525 r18e0a6c  
    4242
    4343#include <synch/spinlock.h>
     44
     45#include <arch/asm.h>
    4446
    4547count_t frames = 0;
  • src/mm/heap.c

    rd896525 r18e0a6c  
    3333#include <panic.h>
    3434#include <arch/types.h>
     35#include <arch/asm.h>
    3536
    3637/*
  • src/mm/vm.c

    rd896525 r18e0a6c  
    3939#include <list.h>
    4040#include <panic.h>
     41#include <arch/asm.h>
    4142
    4243vm_t *vm_create(void)
  • src/proc/scheduler.c

    rd896525 r18e0a6c  
    132132                }
    133133       
    134                 /* avoid deadlock with relink_rq */
     134                /* avoid deadlock with relink_rq() */
    135135                if (!spinlock_trylock(&CPU->lock)) {
    136136                        /*
     
    447447
    448448                        cpu = &cpus[(i + k) % config.cpu_active];
    449                         r = &cpu->rq[j];
    450449
    451450                        /*
     
    454453                         */
    455454                        if (CPU == cpu)
    456                                 continue;
     455                                continue;                               
    457456
    458457restart:                pri = cpu_priority_high();
     458                        r = &cpu->rq[j];
    459459                        spinlock_lock(&r->lock);
    460460                        if (r->n == 0) {
     
    471471                                 * We don't want to steal CPU-wired threads neither threads already stolen.
    472472                                 * The latter prevents threads from migrating between CPU's without ever being run.
    473                                  * We don't want to steal threads whose FPU context is still in CPU
     473                                 * We don't want to steal threads whose FPU context is still in CPU.
    474474                                 */
    475475                                spinlock_lock(&t->lock);
    476476                                if ( (!(t->flags & (X_WIRED | X_STOLEN))) && (!(t->fpu_context_engaged)) ) {
     477                               
    477478                                        /*
    478479                                         * Remove t from r.
  • src/proc/thread.c

    rd896525 r18e0a6c  
    177177                frame_ks = frame_alloc(FRAME_KA);
    178178                if (THREAD_USER_STACK & flags) {
    179                         frame_us = frame_alloc(0);
     179                        frame_us = frame_alloc(FRAME_KA);
    180180                }
    181181
  • src/synch/semaphore.c

    rd896525 r18e0a6c  
    3131#include <synch/waitq.h>
    3232#include <synch/spinlock.h>
     33#include <arch/asm.h>
    3334
    3435void semaphore_initialize(semaphore_t *s, int val)
Note: See TracChangeset for help on using the changeset viewer.