Changeset 1735f3e in mainline for uspace/app/trace/trace.c


Ignore:
Timestamp:
2010-01-31T18:22:37Z (14 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
fc2e71e
Parents:
430de97 (diff), 2e07f62c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge from mainline.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/trace/trace.c

    r430de97 r1735f3e  
    4949#include <io/keycode.h>
    5050#include <fibril_synch.h>
     51#include <sys/types.h>
     52#include <sys/typefmt.h>
    5153
    5254#include <libc.h>
     
    159161        if (rc < 0) {
    160162                printf("Error connecting\n");
    161                 printf("ipc_connect_task(%lld) -> %d ", task_id, rc);
     163                printf("ipc_connect_task(%" PRIdTASKID ") -> %d ", task_id, rc);
    162164                return rc;
    163165        }
     
    198200        printf("Threads:");
    199201        for (i = 0; i < n_threads; i++) {
    200                 printf(" [%d] (hash 0x%lx)", 1+i, thread_hash_buf[i]);
     202                printf(" [%d] (hash %p)", 1+i, thread_hash_buf[i]);
    201203        }
    202204        printf("\ntotal of %u threads\n", tb_needed / sizeof(uintptr_t));
     
    222224        case V_HASH:
    223225        case V_PTR:
    224                 printf("0x%08lx", val);
     226                printf("%p", val);
    225227                break;
    226228
     
    275277
    276278        putchar('(');
    277         if (n > 0) printf("%ld", sc_args[0]);
     279        if (n > 0) printf("%" PRIdSYSARG, sc_args[0]);
    278280        for (i = 1; i < n; i++) {
    279                 printf(", %ld", sc_args[i]);
     281                printf(", %" PRIdSYSARG, sc_args[i]);
    280282        }
    281283        putchar(')');
     
    508510        }
    509511
    510         printf("Start tracing thread [%d] (hash 0x%lx).\n", thread_id, thread_hash);
     512        printf("Start tracing thread [%d] (hash %p).\n", thread_id, thread_hash);
    511513
    512514        while (!abort_trace) {
     
    552554                                break;
    553555                        case UDEBUG_EVENT_THREAD_E:
    554                                 printf("Thread 0x%lx exited.\n", val0);
     556                                printf("Thread %p exited.\n", val0);
    555557                                fibril_mutex_lock(&state_lock);
    556558                                abort_trace = true;
     
    972974        rc = connect_task(task_id);
    973975        if (rc < 0) {
    974                 printf("Failed connecting to task %lld.\n", task_id);
     976                printf("Failed connecting to task %" PRIdTASKID ".\n", task_id);
    975977                return 1;
    976978        }
    977979
    978         printf("Connected to task %lld.\n", task_id);
     980        printf("Connected to task %" PRIdTASKID ".\n", task_id);
    979981
    980982        if (task_ldr != NULL)
Note: See TracChangeset for help on using the changeset viewer.