X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=Robust%2Fsrc%2FBenchmarks%2FSSJava%2FMP3Decoder%2FBitstream.java;fp=Robust%2Fsrc%2FBenchmarks%2FSSJava%2FMP3Decoder%2FBitstream.java;h=373fddeedac513e0c7ea8d7675843411d959648f;hb=15e12c52c54314d14b860b578c46251adb3e8625;hp=02a65a053bb3da19fbedfb92bb8027f0bceb1cbc;hpb=47cc527f574f19b71e92fceac668fb8c0655b13b;p=IRC.git diff --git a/Robust/src/Benchmarks/SSJava/MP3Decoder/Bitstream.java b/Robust/src/Benchmarks/SSJava/MP3Decoder/Bitstream.java index 02a65a05..373fddee 100644 --- a/Robust/src/Benchmarks/SSJava/MP3Decoder/Bitstream.java +++ b/Robust/src/Benchmarks/SSJava/MP3Decoder/Bitstream.java @@ -40,103 +40,101 @@ * REVIEW: much of the parsing currently occurs in the various decoders. * This should be moved into this class and associated inner classes. */ -@LATTICE("FBframebuffer where the next bits are retrieved. */ - @LOC("WP") + private int wordpointer; /** * Number (0-31, from MSB to LSB) of next bit for get_bits() */ - @LOC("BI") + private int bitindex; /** * The current specified syncword */ - @LOC("F") + private int syncword; /** * Audio header position in stream. */ - @LOC("F") + private int header_pos = 0; /** * */ - @LOC("F") + private boolean single_ch_mode; // private int current_frame_number; // private int last_frame_number; - @LOC("F") + private final int bitmask[] = { 0, // dummy 0x00000001, 0x00000003, 0x00000007, 0x0000000F, 0x0000001F, 0x0000003F, 0x0000007F, 0x000000FF, 0x000001FF, 0x000003FF, 0x000007FF, 0x00000FFF, 0x00001FFF, 0x00003FFF, 0x00007FFF, 0x0000FFFF, 0x0001FFFF }; - @LOC("F") + private final PushbackInputStream source; - @LOC("F") + private final Header header = new Header(); - @LOC("F") + private final byte syncbuf[] = new byte[4]; - @LOC("F") + private Crc16[] crc = new Crc16[1]; - @LOC("F") + private byte[] rawid3v2 = null; - @LOC("FF") + private boolean firstframe = true; private BitReserve br; @@ -528,12 +526,12 @@ public final class Bitstream implements BitstreamErrors { /** * Parses the data previously read with read_frame_data(). */ - @LATTICE("GLOBAL>> 16) & 0x0000FFFF); returnvalue >>>= 48 - sum; // returnvalue >>= 16 - (number_of_bits - (32 - @@ -612,7 +610,7 @@ public final class Bitstream implements BitstreamErrors { /** * Set the word we want to sync the header to. In Big-Endian byte order */ - void set_syncword(@LOC("IN") int syncword0) { + void set_syncword( int syncword0) { syncword = syncword0 & 0xFFFFFF3F; single_ch_mode = ((syncword0 & 0x000000C0) == 0x000000C0); } @@ -632,14 +630,14 @@ public final class Bitstream implements BitstreamErrors { * is thrown if the specified number of bytes could not be read * from the stream. */ - @LATTICE("OUT 0) { - @LOC("IN") int bytesread = source.read(b, offs, len); + int bytesread = source.read(b, offs, len); if (bytesread == -1) { while (len-- > 0) { b[offs++] = 0; @@ -660,14 +658,14 @@ public final class Bitstream implements BitstreamErrors { /** * Simlar to readFully, but doesn't throw exception when EOF is reached. */ - @LATTICE("OUT 0) { - @LOC("IN") int bytesread = source.read(b, offs, len); + int bytesread = source.read(b, offs, len); if (bytesread == -1) { break; }