Mercurial > hg > Members > menikon > CbC_xv6
changeset 179:2842d9e65751
fix_skip_codegear
author | anatofuz |
---|---|
date | Mon, 20 Jan 2020 11:24:39 +0900 |
parents | 0ef5c1d852fe |
children | 9f28b86fecc5 f9df567f7f2d |
files | src/gearsTools/lib/Gears/Context.pm src/impl/file_impl_pipe.cbc |
diffstat | 2 files changed, 13 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/src/gearsTools/lib/Gears/Context.pm Fri Jan 17 15:25:05 2020 +0900 +++ b/src/gearsTools/lib/Gears/Context.pm Mon Jan 20 11:24:39 2020 +0900 @@ -30,6 +30,11 @@ for my $cbc_file (@{$self->{compile_sources}}) { open my $fh , '<', $cbc_file; while (my $line = <$fh>) { + if ($line =~ m|//\s*:skip|) { + print "ddddddddd\n"; + next; + } + if ($line =~ /#interface\s*"(.*)\.h"/ || $line =~ /^\/\/\s*data_gear\s*"(.*)\.(?:h|dg)?"/) { push(@{$counter{interfaces}->{$1}},$.); push(@{$self->{data_gears_with_count}->{$1}->{caller}->{$cbc_file}},$.); @@ -41,6 +46,7 @@ next; } + #if ($line =~ /^(\w+)(\*)+ *create(\w+)\(([^]]*)\)/) { # my $interface = $1; # my $implementation = $3;
--- a/src/impl/file_impl_pipe.cbc Fri Jan 17 15:25:05 2020 +0900 +++ b/src/impl/file_impl_pipe.cbc Mon Jan 20 11:24:39 2020 +0900 @@ -34,7 +34,8 @@ file->close = C_closepipe; return file; } -__code statpipe(struct pipe* file, struct stat* st, __code next(...)) { +//Skip: generate_context +__code statpipe(struct pipe* file, struct stat* st, __code next(...)) { //:skip goto next(...); } @@ -60,7 +61,9 @@ goto cbc_sleep(p,&p->nread, &p->lock, next,cbc_piperead1); } -__code cbc_sleep(struct pipe* p, unit* nread, struct spinlock* lock, __code next(...), __code pread(...)){ + +//Skip: generate_context +__code cbc_sleep(struct pipe* p, unit* nread, struct spinlock* lock, __code next(...), __code pread(...)){ //:skip if(proc == 0) { goto cbc_context->panic("sleep"); } @@ -76,7 +79,8 @@ goto cbc_sched(cbc_sleep1); } -__code cbc_sched_stub(struct pipe* p, unit* nread, struct spinlock* lock, __code next(...), __code pread(...)){ +//Skip: generate_context +__code cbc_sched_stub(struct pipe* p, unit* nread, struct spinlock* lock, __code next(...), __code pread(...)){ //:skip proc->chan = chan; proc->state = SLEEPING; proc->lk = lk;