Changeset 741fd16 in mainline for uspace


Ignore:
Timestamp:
2008-11-21T22:14:24Z (17 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
32e6c9c
Parents:
384c488
Message:

Stoppability sections must be much smaller (design error). Also fix deadlock in udebug_stop(). Fix pause functionality in tracer.

File:
1 edited

Legend:

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

    r384c488 r741fd16  
    450450        while (!abort_trace) {
    451451
     452                if (paused) {
     453                        printf("Waiting for resume\n");
     454                        while (paused) {
     455                                usleep(1000000);
     456                                fibril_yield();
     457                                printf(".");
     458                        }
     459                        printf("Resumed\n");
     460                }
     461
    452462                /* Run thread until an event occurs */
    453463                rc = udebug_go(phoneid, thread_hash,
     
    470480                        case UDEBUG_EVENT_STOP:
    471481                                printf("Stop event\n");
    472                                 printf("Waiting for resume\n");
    473                                 while (paused) {
    474                                         usleep(1000000);
    475                                         fibril_yield();
    476                                         printf(".");
    477                                 }
    478                                 printf("Resumed\n");
    479482                                break;
    480483                        case UDEBUG_EVENT_THREAD_B:
     
    581584                if (c == 'q') break;
    582585                if (c == 'p') {
     586                        printf("Pause...\n");
    583587                        paused = 1;
    584588                        rc = udebug_stop(phoneid, thash);
     
    587591                if (c == 'r') {
    588592                        paused = 0;
     593                        printf("Resume...\n");
    589594                }
    590595        }
Note: See TracChangeset for help on using the changeset viewer.