Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(150)

Side by Side Diff: src/trusted/validator_ragel/decoder_test_one_file.sh

Issue 9348082: Move unreviewed files to unreviewed subdirectory (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 #!/bin/bash
2 # Copyright (c) 2012 The Native Client Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 # Checks that a given assembyl file is decoded identically to objdump.
7 #
8 # Usage:
9 # decoder_test_one_file.sh GAS=... OBJDUMP=... DECODER=... ASMFILE=...
10
11 set -e
12 set -u
13
14 # Parse arguments.
15 eval "$@"
16
17 # Sanity check arguments.
18 if [[ ! -x "${GAS% *}" || ! -x "${OBJDUMP% *}" || ! -x "${DECODER% *}" ]] ; then
19 echo >&2 "error: GAS or OBJDUMP or DECODER incorrect"
20 exit 2
21 fi
22
23 if [[ ! -f "$ASMFILE" ]] ; then
24 echo >&2 "error: ASMFILE is not a regular file: $ASMFILE"
25 exit 3
26 fi
27
28 # Produce an object file, disassemble it in 2 ways and compare results.
29 $GAS "$ASMFILE" -o "$ASMFILE.o"
30 rm -f "$ASMFILE"
31 $DECODER "$ASMFILE.o" > "$ASMFILE.decoder"
32 # Take objdump output starting at line 8 to skip the unimportant header that
33 # is not emulated in the decoder test.
34 $OBJDUMP -d "$ASMFILE.o" |
35 tail -n+8 - |
36 cmp - "$ASMFILE.decoder"
37 rm -f "$ASMFILE.o" "$ASMFILE.decoder"
OLDNEW
« no previous file with comments | « src/trusted/validator_ragel/decoder-x86_64.rl ('k') | src/trusted/validator_ragel/gen-decoder.C » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698