mseaborn@chromium.org [Tue, 14 May 2013 18:29:44 +0000 (18:29 +0000)]
Add wrapper library for the nacl_irt_exception_handling IRT interface
Switch src/untrusted/minidump_generator and src/untrusted/crash_dump
over to using the new wrapper library.
Add the wrapper library to the Gyp build.
Minor cleanup to use perror() to report errno status in
minidump_generator.cc.
BUG=https://code.google.com/p/nativeclient/issues/detail?id=2401
TEST=run_minidump_test_irt run_untrusted_crash_dump_test_irt
Review URL: https://codereview.chromium.org/
14876015
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11345
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
ncbray@chromium.org [Mon, 13 May 2013 22:12:28 +0000 (22:12 +0000)]
Enable meta-based validation for shared libraries.
BUG= https://code.google.com/p/chromium/issues/detail?id=224434
R=bsy@google.com
Review URL: https://codereview.chromium.org/
15039022
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11340
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Thu, 9 May 2013 21:38:33 +0000 (21:38 +0000)]
Minidumper: Extend to dump the stack contents
This allows a stack backtrace to be extracted from the minidump.
BUG=https://code.google.com/p/nativeclient/issues/detail?id=3424
TEST=run_minidump_test + manual testing of *.dmp files
Review URL: https://codereview.chromium.org/
15032003
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11327
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Wed, 1 May 2013 22:29:25 +0000 (22:29 +0000)]
Get rid of native_code SCons argument, never default to bitcode=1
Having bitcode=1 be the default under platform=arm was done back when
there was no non-bitcode option for ARM. Removing that special case
makes the SCons behavior consistent across all targets: you only get
bitcode if you pass bitcode=1 explicitly. Places that care already
pass bitcode=1 along with platform=arm.
BUG= none
TEST= trybots
R=dschuff@chromium.org
Review URL: https://codereview.chromium.org/
14789009
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11278
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Wed, 1 May 2013 17:50:01 +0000 (17:50 +0000)]
Never use PNaCl toolchain to build the IRT
Since arm-nacl-gcc is capable of building the IRT and that's how the
Chromium/PPAPI IRT will be built from now on, build irt_core.nexe that
way too. This will make it possible to drop various kinds of kludgery
from the PNaCl build that were done just to enable the IRT build.
BUG= none
TEST= trybots
R=dschuff@chromium.org
Review URL: https://codereview.chromium.org/
14718002
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11273
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
ncbray@chromium.org [Fri, 19 Apr 2013 17:52:56 +0000 (17:52 +0000)]
Add code for attaching file origin information to NaClDescs.
This code is unit tested but not yet in use.
BUG= https://code.google.com/p/chromium/issues/detail?id=224434
Review URL: https://codereview.chromium.org/
14267010
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11213
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
ncbray@chromium.org [Tue, 16 Apr 2013 20:16:18 +0000 (20:16 +0000)]
Add more metadata for validation caching.
BUG= http://code.google.com/p/chromium/issues/detail?id=224434
Review URL: https://codereview.chromium.org/
13684004
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11201
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Tue, 9 Apr 2013 23:17:49 +0000 (23:17 +0000)]
Make sure Clang-supplied runtime libs come from local Clang
When building with Clang, we use a local Clang rather than any one
installed on the system. So we must ensure that the Clang-supplied
libraries we use are those from the local Clang rather than the system.
It's important to list profile_rt as a library that SCons knows about
rather than an explicit -lprofile_rt switch, so that SCons will notice
when the local Clang profile_rt library has changed in an incremental
build.
BUG= none
TEST= trybots
R=jfb@chromium.org
Review URL: https://codereview.chromium.org/
13948010
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11158
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
ncbray@chromium.org [Mon, 1 Apr 2013 23:34:36 +0000 (23:34 +0000)]
Provide metadata to validator to allow faster caching.
This change allows hashless validation caching for the IRT.
BUG= http://code.google.com/p/chromium/issues/detail?id=224434
Review URL: https://chromiumcodereview.appspot.com/
12600034
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11112
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Thu, 28 Mar 2013 21:11:10 +0000 (21:11 +0000)]
Add a scons pnacl finalize step for pnacl_generate_pexe tests.
Most of the ABI stability steps run as part of pnacl-ld.
However, some steps such as stripping nonstable debug
metadata can make debugging hard. Thus, we add one more
step to finalize the ABI.
A new scons Bit 'nonstable_bitcode' can be set by individual tests
to opt out of this prep step if the metadata is needed
(e.g., gdb tests). The test will still run. Add a
commandline flag 'skip_nonstable_bitcode' if it is required
to skip building and running such tests.
An alternative way to opt out is to make the test part of
the nonpexe_test suite.
We need to roll the archived frontend rev too, since finalize
is run during the build portion to properly work with
triggered bots such as the ARM hw bot.
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3348
TEST= trybots + buildbot/buildbot_pnacl_toolchain_tests.sh archived-frontend-test x86-64
Review URL: https://codereview.chromium.org/
12594036
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11090
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
shcherbina@google.com [Tue, 26 Mar 2013 07:26:17 +0000 (07:26 +0000)]
Remove TARGET_ROOT from list of dirs to pre evaluate.
TARGET_ROOT is subdirectory of DESTINATION_ROOT. If we make DESTINATION_ROOT absolute, so will be TARGET_ROOT.
TEST= bots
Review URL: https://codereview.chromium.org/
12472034
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@11059
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bsy@google.com [Tue, 12 Mar 2013 20:42:52 +0000 (20:42 +0000)]
Subprocess creation test, along with sel_universal, nonnacl_util, etc changes to make it work.
The real implementation of the subprocess creation hooks are in the plugin code, but it is difficult to test. we would want a browser test, and that cannot run on the NaCl build bots. So, we need an implementation in sel_universal that "should" implement the same interface and provide some assurance that if the NaCl build bots succeed, the Chromium bots will too.
This CL changes: the windows standalone launcher to not create a new console; the standalone launcher module to use a zygote process for Linux and OSX, since using it to launch multiple processes result in descriptor inheritance issues; and the reverse service interface to fix a potential race condition, where a process's state information might be freed before the RPC reply for the process creation has been sent.
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3318
Review URL: https://codereview.chromium.org/
12461007
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10969
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jfb@chromium.org [Fri, 8 Mar 2013 02:14:44 +0000 (02:14 +0000)]
Clean up coverage bots
The Mac coverage bot has been broken for a while (see bug) and I think
the new Mac GCC is hopelessly beyond repair when it comes to
gcov. Furthermore the NaCl we actually ship on Chrome for Mac is built
with LLVM, it's therefore silly to do coverage with GCC. This CL changes
the Mac coverage bots to use LLVM instead. Some of the tests are
unfortunately broken at the moment, and should get fixed separately
(I'll file a bug once this CL is in). I ran the coverage bots and we do
get coverage results from my change, so even with many tests disabled
things are in a better shape with my change (some coverage, same
compiler as the one we ship NaCl with) than without (no coverage, broken
bot, different compiler).
This CL also cleans up some of the divergences between Mac/Linux/Windows
coverage bots.
TESTS= git try -b nacl-win32-newlib-coverage,nacl-lucid-64-32-newlib-coverage,nacl-lucid-64-64-newlib-coverage,nacl-mac10.6-newlib-coverage
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3283
R= bradnelson@chromium.org
Review URL: https://codereview.chromium.org/
12387091
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10958
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bsy@google.com [Tue, 26 Feb 2013 19:47:29 +0000 (19:47 +0000)]
Serialization library. Useful for sending more complex data in RPCs.
This CL contains a definition for the SerializationBuffer class, which
allows simple numeric types, std::string, and std::vector to be
serialized into a byte buffer for transmission via some IPC mechanism
or for storage. The SerializationBuffer can be constructed from
received data, and the data elements deserialized.
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3318
Review URL: https://codereview.chromium.org/
12316093
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10909
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Wed, 30 Jan 2013 22:12:38 +0000 (22:12 +0000)]
Style: Fix various cases to use a consistent capitalisation of "NaCl"
It's not "NaCL" or "Nacl".
BUG=none
TEST=build
Review URL: https://codereview.chromium.org/
12091074
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10684
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jfb@chromium.org [Mon, 14 Jan 2013 17:04:59 +0000 (17:04 +0000)]
Move CPU features into its own static library.
CPU features has outgrown its original x86-only roots and is used in
more than just the validators. Move it out of there as a second step to
cleaning up this code.
The eventual goal is for CPU features to have similar interfaces for all
CPUs, as well as for some features to work when host and target are
different (e.g. validate an ARM nexe with a certain ARM feature set on
an x86 box).
This CL doesn't change any code beyond:
- moving it;
- updating the includes/include guards;
- fixing silly build scripts.
R= bsy@chromium.org
Review URL: https://codereview.chromium.org/
11864002
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10590
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
shcherbina@google.com [Fri, 28 Dec 2012 02:26:07 +0000 (02:26 +0000)]
Validator_ragel: get rid of dfa_validate_x86_xx libraries in scons build.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=3228
TEST= bots
Review URL: https://chromiumcodereview.appspot.com/
11662023
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10513
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jfb@chromium.org [Wed, 19 Dec 2012 20:56:36 +0000 (20:56 +0000)]
ARM validator: remove checked-in nexe tests.
Auto-generate the nexes from the assembly files instead. This is much
nicer for the trybots because they can't handle checked-in binary files
and fail tests when these get changed.
A few things to note:
- The tests now only run when platform=arm, and do not run when
generating pexes.
- I also had to use C-style comments instead of at-symbols.
- I added unified ARM syntax annotation, mokey-copy from a test Roland
added elsewhere.
- The test test_external_jumps.S wanted to use `b 0` but couldn't.
It now can, so I added that and left `b _start - 0x20000` too.
- None of the other assembly files have any code changes.
- The tests are disabled for Windows, but the entire scons build also
is disabled for Windows. I'll enable everything but the tests in a
different CL, and then fix issue #3217 in yet another CL.
R= kschimpf@google.com, mcgrathr@chromium.org, jvoung@chromium.org
TESTS= ./scons platform=arm small_tests
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3194
Review URL: https://codereview.chromium.org/
11618009
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10484
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Thu, 13 Dec 2012 19:14:34 +0000 (19:14 +0000)]
Fix SCons @file logic to work with non-Cygwin GNU tools
Tools built by Cygwin (the legacy x86 toolchain) and tools built
without Cygwin (the new ARM toolchain and future toolchains) treat the
@file contents differently vis a vis embedded backslashes. There is
no perfect solution, but this change is an adequate kludge for our
SCons build to work with either toolchain. Details are in the comments.
With this, the Windows bot using the arm-nacl-gcc toolchain can be enabled.
BUG= none
TEST= trybots
R=bradnelson@google.com
Review URL: https://codereview.chromium.org/
11567014
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10456
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Wed, 14 Nov 2012 00:17:58 +0000 (00:17 +0000)]
Do not require toolchains to exist in built_elsewhere=1 mode
When built_elsewhere=1 is passed to scons, we should not require
that toolchain directories exist. We get this requirement indirectly
when the PNaClGetNNaClEnv method is used, even though we'll clobber
the settings and not use the toolchain anyway.
BUG= none
TEST= trybots
R=bradnelson@google.com
Review URL: https://codereview.chromium.org/
11365240
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10261
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Tue, 13 Nov 2012 00:05:45 +0000 (00:05 +0000)]
Enable arm-nacl-gcc for pnacl callingconv_ppapi test
Now that there is a toolchain available, this test can be enabled
for proper interoperability testing between the two compilers.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=3103
TEST= trybots
R=robertm@google.com
Review URL: https://codereview.chromium.org/
11361226
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10234
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Fri, 9 Nov 2012 19:40:51 +0000 (19:40 +0000)]
Make naclsdk find ARM toolchains
The new arm-nacl-gcc toolchain fit the established pattern, so
we just have to use them. The dictionary mapping platform and
target to toolchain name was just a repetitive way of expressing
the simple uniform formula, so I removed it instead of just adding
'arm' elements.
BUG= https://code.google.com/p/nativeclient/issues/detail?id=3086
TEST= trybots + local test of './scons platform=arm native_code=1'
R=bradnelson@google.com
Review URL: https://codereview.chromium.org/
11312170
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10225
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Mon, 22 Oct 2012 21:28:57 +0000 (21:28 +0000)]
Enable GDB tests for PNaCl
Change nacksdk.py to ensure that the GDB path is set up when
env.Bit('bitcode') is set.
Use GetTranslatedNexe() so that these tests can run when using the
sandboxed translator and, more generally, when pnacl_generate_pexe=1.
Tweak GetTranslatedNexe() so that it returns the nexe target rather
than a list containing the nexe target, because tests/gdb/nacl.scons
calls .abspath on the target.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=3091
TEST=./scons gdb_tests bitcode=1
Review URL: https://codereview.chromium.org/
11248002
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10064
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
phosek@chromium.org [Tue, 16 Oct 2012 08:58:39 +0000 (08:58 +0000)]
Generic containers moved into a separate module, split each container into individual source file.
The tests will be provided in the follow up change list as a part of larger refactoring.
BUG=
TESTS=trybots
Review URL: https://codereview.chromium.org/
10905317
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@10006
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
petarj@mips.com [Mon, 24 Sep 2012 23:11:47 +0000 (23:11 +0000)]
[MIPS] Implementation of sel_ldr for MIPS architecture.
Set of changes needed for sel_ldr support for MIPS architecture.
The commit queue is not working for NaCl at the moment, so we are committing with:
NOTRY=true
However, we have run a try job manually, and it passed fine.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2275
TEST= pnacl/build.sh misc-tools
Review URL: https://chromiumcodereview.appspot.com/
10919162
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9827
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bsy@google.com [Thu, 20 Sep 2012 20:42:11 +0000 (20:42 +0000)]
apoptosis code to detect thread capture. a test injection framework.
the test injection framework allows test behavior to be injected into
the normal program, so there's no need to create a special skeletal
framework to initialize just enough to run the test. the injection is
by creating a one-line macro invocation at natural junctures in the
code, so that a test-injection table of function pointers can be
checked. the table is designed so that it is a const table that is
linked into the main executable -- and the table is responsible for
pulling in any "scary" test functions that are not appropriate for a
production release. with -Wno-missing-initializers, adding to the
test table does not require edits of previously created tests.
the main executable and any tests that do not use the test injection
framework get a null table of test injection function pointers.
also tested by patching into native_client dir in Linux x86-64 chrome
build to ensure that gyp file changes are okay wrt plugin
dependencies.
TEST= run_nacl_thread_capture_test
Review URL: https://chromiumcodereview.appspot.com/
10910198
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9792
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Thu, 13 Sep 2012 19:42:17 +0000 (19:42 +0000)]
DEPS in updated pnacl toolchains
This brings in the updated pnacl toolchains: the fat 32/64 bit linux toolchain
and the 64 bit mac toolchain.
R=jvoung@chromium.org,noelallen,bradn
BUG=none
Review URL: https://chromiumcodereview.appspot.com/
10914239
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9730
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 11 Sep 2012 18:31:43 +0000 (18:31 +0000)]
Make pnacl toolchain tester bot find the right toolchain.
SCons currently no longer supports 64-bit sdks, but the
tester bots: download the 32-bit host TC, clobber the 32-bit
host tc, build a 64-bit one and then fail to find the
32-bit one.
This adds a pnaclsdk_mode="custom:<path>" flag so that we
can redirect scons to the "right" toolchain, e.g., while
running "pnacl/build.sh sdk newlib" we can pick the TC that
we had just built, and while running the archived frontend
test we can pick the archived frontend.
Also move some of the 32-bit vs 64-bit configuration stuff
closer together.
Call out some of the rest of the hardcoded paths that we
will need to change.
BUG= red bots!
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2922
TEST=bash buildbot/buildbot_pnacl_toolchain_tests.sh tc-test-bot x86-64
Review URL: https://chromiumcodereview.appspot.com/
10919196
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9702
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
noelallen@google.com [Sun, 9 Sep 2012 22:06:35 +0000 (22:06 +0000)]
Change naclsdk.py site tool to chose only 32 bit pnacl toolchain.
trb=dschuff@google.com
Review URL: https://chromiumcodereview.appspot.com/
10910152
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9682
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Tue, 4 Sep 2012 23:44:43 +0000 (23:44 +0000)]
Create a "sel_main_chrome" Gyp library for Chromium to depend on
This will allow the Chromium Gyp files to be cleaned up so that they
do not depend on "sel" or "platform_qualify" directly but instead just
depend on this single entry point target.
Also change the Scons build similarly and change it to reflect the
real dependencies between components.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2832
TEST=build
Review URL: https://chromiumcodereview.appspot.com/
10909069
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9633
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bradnelson@google.com [Wed, 22 Aug 2012 21:57:35 +0000 (21:57 +0000)]
Refactor ppapi libs scons build description.
Inlining PPAPI_LIBS and NON_PPAPI_BROWSER_LIBS.
Now the chrome_browser_tests is only supported with the IRT,
inline PPAPI_LIBS and NON_PPAPI_BROWSER_LIBS.
Leaving PPAPI_LIBS for now as chrome side still uses it.
Add ppapi_cpp -> ppapi and testrunner_browser -> ppapi dependencies in library_deps.py and use where we can.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2957
TEST=None
R=mseaborn@chromium.org
Review URL: https://chromiumcodereview.appspot.com/
10872020
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9538
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Fri, 17 Aug 2012 22:08:47 +0000 (22:08 +0000)]
Debug stub: Move port/* and gdb_rsp/* into debug_stub/
The "port" directory is poorly named, and there is no particular need
to split the debug stub between "debug_stub" and "gdb_rsp"
directories. Moving the files will allow the debug stub to be
simplified further.
Merge gdb_rsp.gyp into debug_stub.gyp.
Merge gdb_rsp/build.scons into debug_stub/build.scons.
Remove the unused file port.gyp.
Remove gdb_rsp/OWNERS, which is the same as debug_stub/OWNERS.
Merge the "debug_stub_init" library into "debug_stub", since we no
longer have a circular dependency between "debug_stub" and "gdb_rsp".
The dependency of "sel" on "debug_stub" was removed in an earlier
change, so the comment in service_runtime/build.scons about a circular
dependency can be removed.
Remove an incorrect comment about PPAPI from debug_stub/build.scons
and remove an obsolete comment about Linux/Mac.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2897
TEST=Scons and Gyp builds
Review URL: https://chromiumcodereview.appspot.com/
10834366
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9505
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Sat, 11 Aug 2012 02:22:57 +0000 (02:22 +0000)]
Cleanup: Remove unused #defines of "_WINDOWS" and "_CONSOLE"
Nothing in the NaCl or PPAPI trees uses these symbols.
BUG=none
TEST=build
Review URL: https://chromiumcodereview.appspot.com/
10854101
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9445
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
arbenson@google.com [Thu, 9 Aug 2012 17:52:36 +0000 (17:52 +0000)]
Add a "hello world" test for the zero-based sandbox.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2927
TEST=./scons run_hello_world_test \
x86_64_zero_based_sandbox=1 bitcode=1 platform=x86-64
Review URL: https://chromiumcodereview.appspot.com/
10855042
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9427
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Thu, 9 Aug 2012 01:35:38 +0000 (01:35 +0000)]
Debug stub: Test single-stepping/continuing with other threads suspended
The debug stub allows GDB to single-step or a continue one thread
while all other threads remain suspended. This change adds tests to
cover this. The test checks that other threads remain properly
suspended.
This is in preparation for changing how the debug stub suspends
threads -- the new test catches bugs in my work-in-progress change
which are otherwise not detected.
This test checks whether variables get modified by suspended threads.
We use "nm" to find variables' addresses. I'm not attempting to make
this work with non-ARM PNaCl. I've changed the nacl.scons file to use
AllowInlineAssembly() for consistency with other assembly-using tests
where we don't attempt to get x86 inline assembly to work with PNaCl.
We move AssertReplySignal() to the top level so that it can be used by
the new tests, which are in a separate class to provide a new scope
for clarity. This involves defining an AssertEquals() that is usable
outside of the class.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2948
TEST=run_debug_stub_test
Review URL: https://chromiumcodereview.appspot.com/
10829230
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9416
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pasko@google.com [Tue, 17 Jul 2012 13:09:12 +0000 (13:09 +0000)]
validator_ragel: replace a run-time switch with compile time switch
By default the build assumes we want the current production validator.
To build with the new validator:
* with scons:
validator_ragel=1
* with GYP:
GYP_DEFINES=nacl_validator_ragel=1
One problem: the library dependencies change with flipping the validator_ragel
flag in scons, hence we cannot use a static table of library dependencies in
library_deps.py.
Modified library_deps.py to add certain validator libraries to the link sequence depending on how "validator_ragel" bit is set. Design-wise, it is not beautiful to make library_deps.py be aware of command-line flags, but it's the most compact change we found to do the job.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2868
TEST=GYP_DEFINES=nacl_validator_ragel=1 ./native_client/build/gyp_nacl && make
TEST=cd native_client && ./scons -j8 --mode=dbg-host --validator_ragel platform=x86-64
Review URL: https://chromiumcodereview.appspot.com/
10700114
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9159
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 10 Jul 2012 17:47:01 +0000 (17:47 +0000)]
Add an alias 'pnacl_support_extension' for rebuilding the pnacl
extension during testing. Also move the output directory to a fixed
subdir of scons-out instead of a fixed dir under chromebinaries so
that it is easier to clobber (rather than clobber chromebinaries).
Since scons dependency checking doesn't seem to work with
the toolchain directory, we also always build this now.
BUG= none
TEST= trybots
Review URL: https://chromiumcodereview.appspot.com/
10704015
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9101
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bradnelson@google.com [Tue, 3 Jul 2012 23:03:24 +0000 (23:03 +0000)]
Dropping unused wix tool + dependency.
This might have been used for the firefox installer at some point.
Dropping it.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2889
TEST=None
R=bradchen@chromium.org
Review URL: https://chromiumcodereview.appspot.com/
10700096
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9091
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Fri, 29 Jun 2012 16:55:21 +0000 (16:55 +0000)]
Clean up toolchain command/option selection
This cleans up the selection of native-code toolchain details to be
more clear and table-driven. It also drops the support for the
obsolete style of tool names such as 'nacl-gcc' and 'nacl64-gcc'.
This now works for the existing standard cases, and also for
naclsdk_mode=custom:... specifying a next-generation toolchain
that uses 'arm-nacl-...' or 'i686-nacl-...'.
BUG= none
TEST= trybots
R=bradnelson@google.com
Review URL: https://chromiumcodereview.appspot.com/
10704036
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9060
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Mon, 25 Jun 2012 22:02:35 +0000 (22:02 +0000)]
Add a test for sel_main_chrome.c
The existing sel_main_chrome_test.c only checked that
sel_main_chrome.c can be linked successfully, and did not try to run
it. Since I broke sel_main_chrome.c in r8988 (fixed in r8997), it's
time to improve the test to catch this kind of mistake.
We extend the test to use sel_main_chrome.c to run hello_world.nexe
and check its output.
Change library_deps.py to declare some of the "sel" library's
dependencies.
Fix nacl_valgrind_hooks.h to be #includable from C++.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2758
TEST=run_sel_main_chrome_test
Review URL: https://chromiumcodereview.appspot.com/
10604003
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9032
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pasko@google.com [Fri, 22 Jun 2012 10:11:10 +0000 (10:11 +0000)]
Refactor the process of choosing validators.
On startup make a choice of validator implementation: write the choice as
function pointers in NaClApp. This opens a possibility to add more experimental
validators (such as MIPS) without having to add platform-specific stub
implementations.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2737
TEST=functionality must be left unchanged
Review URL: https://chromiumcodereview.appspot.com/
10134056
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@9009
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@chromium.org [Tue, 12 Jun 2012 18:21:29 +0000 (18:21 +0000)]
Cleanup some unused flags related to pnacl's sandboxed translator built as a
shared image.
These became obsolete after:
http://codereview.chromium.org/
10546057/
BUG= none
TEST= manual
Review URL: https://chromiumcodereview.appspot.com/
10536091
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8899
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@chromium.org [Sat, 9 Jun 2012 01:59:38 +0000 (01:59 +0000)]
Remove flag passed to pnacl translators which has no effect
as 'USE_DEFAULT_CMD_LINE': '1' (driver_env.py)
Review URL: https://chromiumcodereview.appspot.com/
10532076
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8870
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
petarj@mips.com [Fri, 1 Jun 2012 15:59:30 +0000 (15:59 +0000)]
Initial patch for MIPS architecture that includes implementation of the validator, as well as the test code and script changes that enable building MIPS binutils and test executables.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2275
TEST=pnacl/build.sh misc-tools ; src/trusted/validator_mips/testdata/compile_tests.sh
Review URL: https://chromiumcodereview.appspot.com/9979025
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8780
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Fri, 1 Jun 2012 00:05:41 +0000 (00:05 +0000)]
SCons build tweaks to enable using a custom native ARM toolchain
These tweaks add the native_code=1 option to the SCons command line, which
counteracts the otherwise default bitcode=1 when platform=arm. Also tweak
various SCons files so that ARMness and bitcodeness are properly separated.
For now, this only really works when using naclsdk_mode=custom:... to point
at a hand-built arm-nacl native toolchain.
BUG= none
TEST= trybots
R=sehr@google.com
Review URL: https://chromiumcodereview.appspot.com/
10442070
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8771
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Wed, 23 May 2012 20:41:31 +0000 (20:41 +0000)]
scons support for building pnacl shared libs via bitcode
The main problems addressed here is that the notion of
bitcode and native file is not quite compatible with
scons' way of doing things (assuming pnacl_geneate_pexe=0).
Currently we just build everything as native code and even the bitcode
link uses native code.
The solution is to pretend everything is native but make
sure that bitcode intermediate files (i.e. libraries)
are copied to the staging directories.
A wrapper scripts bridges the gap between the bitcode
world and the native code.
The script is similar to a driver but intentionally named differently
as it is not a suggested way of using the toolchain.
The script is kept simple and only meant to handle our scons usage scenarios.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2765
TESTS= manual
Review URL: https://chromiumcodereview.appspot.com/
10386210
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8694
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
halyavin@google.com [Mon, 21 May 2012 09:21:09 +0000 (09:21 +0000)]
Test for debug stub with real gdb.
Glibc not supported because corresponding changes to gdb
haven't committed yet.
I have to remove the flag that libraries enumeration is
supported by debug stub since new version of gdb produces
errors.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2764
TEST=scons platform=... --mode=nacl,opt-host run_stepi_after_break_test
Review URL: https://chromiumcodereview.appspot.com/
10350007
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8657
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pasko@google.com [Tue, 24 Apr 2012 11:04:08 +0000 (11:04 +0000)]
validator_ragel: Link into TCB, use under env var
In both Chrome and sel_ldr environment variable
NACL_DANGEROUS_USE_DFA_VALIDATOR is used to replace the current validator with
the new one.
WARNING:
WARNING:
WARNING: The size increase of the runnable binaries resulted by this change will
likely trigger the "perf_expectation" regression when this change gets pulled
into Chrome via DEPS roll.
Size implications:
0. absolute values of size increase are equal among sel_ldr, nacl_helper and the
chrome binary. On Linux the validator library gets pulled into the
downloadable chrome package twice (in nacl_helper and chrome).
1. 32bit validator size is negligible (within 40K on each platform uncompressed)
2. with 64 validator there are 2 cases: Linux and Windows.
2.1. On Linux the optimized stripped sel_ldr gets increased by 400K (was: 510K).
The 7zipped size increase for nacl_helper is 108K (was: 884K).
2.2. On Windows the optimized sel_ldr gets increased by 1MB (was: 955K). When
7zipped the increase is 101K (great compression!). When we get to optimize
the Windows64 build the uncompressed size increase is expected to be
significantly smaller: about 350K. This is a work in progress.
Overall package size increase is expected to be:
Windows64:
7zipped - about 101K
uncompressed - about 1MB (can be reduced later)
Linux64:
7zipped - about 216K
uncompressed - about 800K
Windows32, all MacOS variants:
uncompressed - less than 40K
Linux32:
uncompressed - less than 80K
Linking another validator in statically has the advantage of being able to run
two validators side by side for some time taking the current validator's answer
as authoritative. Also, it does not increase the hassle in the build and
deployment systems which we have a lot already.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2597
TEST=./scons --mode=dbg-host platform=x86-64 run_dfa_validator_hello_world_test
Review URL: https://chromiumcodereview.appspot.com/
10070010
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8372
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Fri, 20 Apr 2012 21:48:14 +0000 (21:48 +0000)]
Scons: Move some library dependency declarations into library_deps.py
Declare dependencies of the 'sel' library in order to fix some of the
worst duplication.
Change the code in library_deps.py to take dependencies for 'sel' from
both LIBRARY_DEPENDENCIES_DEFAULT and PLATFORM_LIBRARY_DEPENDENCIES.
Replace the transitive-closure implementation in library_deps.py with
one that is simpler and easier to understand.
BUG=none
TEST=build
Review URL: https://chromiumcodereview.appspot.com/
10167012
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8348
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Fri, 20 Apr 2012 06:35:03 +0000 (06:35 +0000)]
Scons: Remove duplication of VALIDATOR_LIBS list and use library_deps.py instead
BUG=none
TEST=build
Review URL: https://chromiumcodereview.appspot.com/
10158002
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8332
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Thu, 19 Apr 2012 17:42:59 +0000 (17:42 +0000)]
Remove references to SDL from the Scons build
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2740
TEST=trybots
Review URL: https://chromiumcodereview.appspot.com/
10117035
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8316
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 3 Apr 2012 00:24:27 +0000 (00:24 +0000)]
Wrap AR command lines in a temp file as well, in case it gets
too long, e.g., for the pnacl windows toolchain bot.
Previously, this only happened for link commands.
BUG= bot redness
TEST= trybots
Review URL: https://chromiumcodereview.appspot.com/9968063
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8154
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Fri, 30 Mar 2012 19:17:15 +0000 (19:17 +0000)]
Remove code for non-clang frontends from SConstruct and naclsdk.py
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2697
Review URL: https://chromiumcodereview.appspot.com/9882001
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8144
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Fri, 30 Mar 2012 15:42:20 +0000 (15:42 +0000)]
Refactor buildbot_pnacl.sh and implement new test scheme
This CL makes pnacl_generate_pexe=1 the default and tests the nonpexe_tests
separately. It also simplifies buildbot_pnacl.sh
R= jvoung@google.com,sehr@google.com,robertm@google.com
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2609
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2407
TEST= pnacl tests
Review URL: https://chromiumcodereview.appspot.com/9791026
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8140
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Mon, 26 Mar 2012 23:32:08 +0000 (23:32 +0000)]
Enable some sandboxed translation tests
Except do it right this time.
Summary:
Use the standalone sandboxed translator driver for all arches in sbtc mode.
Don't stub-out the translate command; actually translate.
Adjust buildbot scripts to run the right tests, and don't build the
prerequisites on arm hw
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2407
TEST= arm bots
Review URL: https://chromiumcodereview.appspot.com/9853033
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8114
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Mon, 26 Mar 2012 15:54:42 +0000 (15:54 +0000)]
Revert the part of 8104 that broke the build
R= robertm
BUG=none
TEST=arm bots
Review URL: https://chromiumcodereview.appspot.com/9857013
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8107
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Sat, 24 Mar 2012 00:23:02 +0000 (00:23 +0000)]
Enable some sandboxed translator tests on arm hardware
Also use the driver in the pnacl_translator directory for sandboxed translation on all architectures.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2407
TEST= all arm
Review URL: https://chromiumcodereview.appspot.com/9836060
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8104
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
sehr@google.com [Fri, 23 Mar 2012 23:19:31 +0000 (23:19 +0000)]
Complete changes of tarball names, roll DEPS to get first newly-named tarballs.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2547
TEST=none
Review URL: https://chromiumcodereview.appspot.com/9835060
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8102
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Thu, 22 Mar 2012 17:59:15 +0000 (17:59 +0000)]
Change built_elsewhere flag to work with pexe mode
Instead of ignoring all dependencies for a test target, we replace the builders (CC CXX et al) except for translate with no-ops.
Also run some basic pexe mode tests on arm, and tweak the pruning process before uploading to the hw bot( and give the tarball a better name).
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2609
TEST=bots
Review URL: https://chromiumcodereview.appspot.com/9824001
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8091
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Fri, 16 Mar 2012 00:22:54 +0000 (00:22 +0000)]
Emit brief command strings for pexe translation.
Also fixes the strip command to do the same.
R=ncbray@google.com,mseaborn@chromium.org
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com/9703089
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8041
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mseaborn@chromium.org [Wed, 14 Mar 2012 23:39:14 +0000 (23:39 +0000)]
Scons: Simplify GetTranslatedNexe()
Use Scons's automatic dependency tracking.
Remove unused "trans_flags" variable.
This addresses some review comments from
https://chromiumcodereview.appspot.com/9696046/.
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2609
TEST=small_tests bitcode=1 pnacl_stop_with_pexe=1
Review URL: https://chromiumcodereview.appspot.com/9695064
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8031
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Tue, 13 Mar 2012 23:33:11 +0000 (23:33 +0000)]
Rename pnacl_stop_with_pexe to pnacl_generate_pexe
Since we actually do want to translate and run tests, and not
stop.
(see https://chromiumcodereview.appspot.com/9696046/ )
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2609
TEST=pnacl_generate_pexe tests
Review URL: https://chromiumcodereview.appspot.com/9691062
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8017
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Tue, 13 Mar 2012 21:48:55 +0000 (21:48 +0000)]
Add test running support for tests generated as pexes.
Hooks into CommandSelLdrTestNacl et al to make the translation part of the test.
R=robertm,jvoung,sehr,Karl
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2609
TEST=smoke_tests,large_tests
Review URL: https://chromiumcodereview.appspot.com/9696046
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@8014
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
mcgrathr@chromium.org [Sat, 10 Mar 2012 00:09:11 +0000 (00:09 +0000)]
Use SCons feature to hide long command lines in temporary files on Windows
Some of our linking commands have grown so long they hit some Windows
limits on command line length. Fortunately, the toolchain and SCons
support a way to work around the limitation.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2648
TEST= trybots
R=dschuff@google.com
Review URL: https://chromiumcodereview.appspot.com/9665023
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7985
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Wed, 7 Mar 2012 22:09:10 +0000 (22:09 +0000)]
Disallow pnacl_stop_with_pexe with --nacl_glibc x86-64 for now,
and allow a few libs to be built under --nacl_glibc for now.
(Alleviate x86-64 toolchain bot redness)
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2630
TEST=
Review URL: https://chromiumcodereview.appspot.com/9623014
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7973
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Fri, 2 Mar 2012 21:26:29 +0000 (21:26 +0000)]
Add a new scons variabe "pnacl_stop_with_pexe" which will prevent pnacl from
producing any native images - just pexes.
Tests will not work with this setting and it is mostly useful for
generating pre-build binaries like so:
./scons platform=arm bitcode=1 do_not_run_tests=1 run_sleep_test pnacl_stop_with_pexe=1
This will generate the pexe necessary to run the test run_sleep_test.
NOTE: There seems to be a problem with the pexes not being moved into
the staging dir
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2630
Review URL: https://chromiumcodereview.appspot.com/9570034
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7935
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Sat, 18 Feb 2012 16:01:46 +0000 (16:01 +0000)]
* redirect.bat: Remove fixed-location PATH hack. Instead, the driver now expects "python" to be in the %PATH%.
* naclsdk.py: Add ../third_party/python_26 to the PATH for the PNaCl driver, when invoked from SCons.
* driver_tools.py: Add missing pathtools.tosys
* driver_env.py:
Use "clang -ccc-cxx" instead of "clang++" for C++ compilation.
"clang++" is a symlink, which is not executable from Windows Python.
TBR= jvoung
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2286
Review URL: https://chromiumcodereview.appspot.com/9355028
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7845
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bradnelson@google.com [Fri, 17 Feb 2012 17:14:27 +0000 (17:14 +0000)]
Adding untrusted crash dump / stack trace tests.
This demonstrates using hardware exception handling support to produce
stack traces in crashed modules.
Not yet handled:
- 64-bit
- registers
- upload of dumps
- call frame variable/parameter decoding
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2595
TEST=untrusted_crash_dump_test,inbrowser_untrusted_crash_dump_test
R=mseaborn@chromium.org,ncbray@chromium.org
Review URL: https://chromiumcodereview.appspot.com/9316125
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7825
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Thu, 9 Feb 2012 18:51:51 +0000 (18:51 +0000)]
Turn on testing of default commandlines for the pnacl sandboxed translator.
Review URL: https://chromiumcodereview.appspot.com/9365028
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7763
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 7 Feb 2012 06:01:53 +0000 (06:01 +0000)]
Accidentally committed scons part before toolchain was ready... plus other issues with the ARM IRT.
TBR=ncbray@google.com
Review URL: https://chromiumcodereview.appspot.com/9350009
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7739
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 7 Feb 2012 01:54:06 +0000 (01:54 +0000)]
Pnacl driver / test-script support for pnacl LLC/LD default commandlines.
Make scons use_sandboxed_translator=1 use the default command lines
where possible to ensure this is tested.
Some tests deviate from the normal use case. In those situations,
the driver will detect it and revert back to a custom commandline.
Pull in LD change: http://codereview.chromium.org/9314012/
Pull in LLC change: http://codereview.chromium.org/9309017/
Review URL: https://chromiumcodereview.appspot.com/9315012
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7738
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Thu, 26 Jan 2012 20:29:58 +0000 (20:29 +0000)]
Add support for generating nmfs for pnacl pexes with glibc (vs pnacl nexes).
TBR=sehr,robertm,pdox
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2546
TEST= run_pnacl_example_browser_test with --nacl_glibc, and it gets past the nmf generation stage.
Review URL: https://chromiumcodereview.appspot.com/9169092
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7682
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Fri, 13 Jan 2012 06:13:31 +0000 (06:13 +0000)]
Combines newlib and glibc builds.
After this CL, the PNaCl install directory will look like this:
newlib/ - Newlib toolchain
glibc/ - GlibC toolchain
pkg/ - Common stuff (LLVM & binutils)
lib-x86-32/ - Native libraries X86-32
lib-x86-64 - Native libraries X86-64
lib-arm/ - Native libraries ARM
tools-sb/ - Sandboxed translator
tools-arm/ - ARM sel_ldr
tools-x86/ - arm-ncval for x86
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2452
Review URL: http://codereview.chromium.org/9158034
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7586
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Sun, 4 Dec 2011 21:16:58 +0000 (21:16 +0000)]
Switch the nop pnacl x86-64 IRT shim to the real one generated from IDL.
We add pnacl_irt_shim to the Implicit Libs for pnacl x86-64 runs
so that we get the freshest version instead of whatever is in the toolchain
tarball.
R=robertm@google.com,sehr@google.com
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2413
TEST= ./scons bitcode=1 platform=x86-64 chrome_browser_tests
Review URL: http://codereview.chromium.org/8776023
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7353
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Sat, 3 Dec 2011 01:29:18 +0000 (01:29 +0000)]
Fix a library path bias accidentally introduced into the newlib-based build.
It was introduced when the library path (NACL_SDK_LIB) was changed for the GlibC-based build.
SCons is not supposed to give pnacl-clang -L to the native directories when the front-end
is operating in pure bitcode mode.
Also, re-enable the pnacl_client_translator test, except for missing_ld and missing_llc which
are still failing.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2470
Review URL: http://codereview.chromium.org/8787008
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7346
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Fri, 2 Dec 2011 19:57:59 +0000 (19:57 +0000)]
Scons treats .s and .S differently:
.s files are routed through $AS while .S files are routed
through the $CC driver, which will also pre-process them with cpp.
This change routes .S files through a new Scons variable $ASPP.
For now this will be identical to $CC.
Eventually, this will make it possible to route .S files through a different driver for PNaCl where we do not want $CC to handle assembly files.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=1966
TESTS= trybots
Review URL: http://codereview.chromium.org/8775055
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7340
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Thu, 17 Nov 2011 17:09:14 +0000 (17:09 +0000)]
Retry r7206
Roll toolchain DEPS, and commit second part of CL:
http://codereview.chromium.org/8575005/
TBR= robertm
Review URL: http://codereview.chromium.org/8587032
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7215
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Thu, 17 Nov 2011 14:27:56 +0000 (14:27 +0000)]
Revert r7206.
TBR= robertm
Review URL: http://codereview.chromium.org/8574059
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7209
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Thu, 17 Nov 2011 12:47:15 +0000 (12:47 +0000)]
Roll toolchain DEPS, and commit second part of CL:
http://codereview.chromium.org/8575005/
TBR=krasin
Review URL: http://codereview.chromium.org/8589021
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7206
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Tue, 8 Nov 2011 22:20:12 +0000 (22:20 +0000)]
Fix problem where shared libs in arm trusted builds were built with -static
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2424
Review URL: http://codereview.chromium.org/8497021
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7127
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Tue, 8 Nov 2011 21:23:44 +0000 (21:23 +0000)]
Removed some debug statements and one line of dead code that went in:
http://codereview.chromium.org/8321008/
Review URL: http://codereview.chromium.org/8501017
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7124
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Tue, 8 Nov 2011 17:54:24 +0000 (17:54 +0000)]
Cleanup of scons compile/link command line generation.
This change simplifies the generation of compile/link command lines.
It introduces a notion of BASE_flags, besides the EXTRA_flags
for the most common compile/link commands.
Primary benefits:
* command line generation process becomes more discoverable.
* it is no longer necessary to tie '-m32' and friends directly to $CC
* several tests that do scary command line manipulation can be simplified
Secondary benefits
* the recursion level for evaluation the command lines is reduced by
one for many nacl targets which should improve scons performance somewhat
Also removed the completely ununsed EXTRA_CCFLAGS and nacl_ccflags features
Review URL: http://codereview.chromium.org/8321008
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7119
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
krasin@chromium.org [Mon, 7 Nov 2011 23:18:25 +0000 (23:18 +0000)]
Remove llvmgcc frontend support from SCons.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=404
Review URL: http://codereview.chromium.org/8490021
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@7115
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Fri, 21 Oct 2011 01:17:53 +0000 (01:17 +0000)]
Test intermixing pnacl-clang, pnacl-gcc, and nacl-gcc generated code in the callingconv test.
Although a large part of the callingconv test remains disabled due to known ABI compatibility problems, eventually this test will help detect and prevent ABI changes.
Review URL: http://codereview.chromium.org/8366024
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6999
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Tue, 18 Oct 2011 20:22:46 +0000 (20:22 +0000)]
Make native .so generation the default for PNaCl.
This still creates .pso files (bitcode shared objects) behind the scenes,
but they are immediately translated to .so files.
Ideally, SCons should be aware of the .pso vs. so distinction. But doing this
will be very tricky, and should not block getting the GlibC tests running
on the PNaCl bots.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2311
Review URL: http://codereview.chromium.org/8314008
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6968
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Tue, 18 Oct 2011 19:21:09 +0000 (19:21 +0000)]
Cleanup dynloader loader test setup to use pnacl helpers and make it possible
to debug the case for bitcode=1 platform!=arm
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2368
Review URL: http://codereview.chromium.org/8317021
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6966
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jasonwkim@google.com [Fri, 14 Oct 2011 16:47:49 +0000 (16:47 +0000)]
Remove dead code
R=pdox
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/8275020
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6931
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
nfullagar@google.com [Thu, 13 Oct 2011 19:42:54 +0000 (19:42 +0000)]
Enable variadic macros, naclsdk.py
TEST= trybots
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2321
Review URL: http://codereview.chromium.org/8271012
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6918
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Wed, 12 Oct 2011 19:48:05 +0000 (19:48 +0000)]
Some adjustments to the driver and SCons to make the scons glibc tests work with PNaCl.
1) Have the driver use robertm's binutils extension "--add-dt-needed" to set the dependencies on the output .so file during translation of .pso. Previously, the translation process needed to be able to find the actual library which the .pso had been linked against.
2) Add libppapi.pso to satisfy dependencies on 'ppapi'.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2311
Review URL: http://codereview.chromium.org/8230030
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6909
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 11 Oct 2011 23:05:08 +0000 (23:05 +0000)]
Point pnacl glibc NACL_SDK_INCLUDE somewhere that exists.
Otherwise, when you run scons with bitcode=1 and --nacl_glibc,
ValidateSdk() will complain that it can't find stdio.h.
R=pdox@google.com
BUG=http://code.google.com/p/nativeclient/issues/detail?id=2311
TEST=
Review URL: http://codereview.chromium.org/7572011
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6903
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Fri, 7 Oct 2011 21:05:36 +0000 (21:05 +0000)]
Get rid of "pnacl_use_clang" bit, and replace with "pnacl_frontend"
parameter which can be set to "clang", "llvmgcc", or "dragonegg".
For example:
./scons bitcode=1 pnacl_frontend=clang ...
This does not alter the default frontend selection, which is currently Clang for newlib builds, and llvm-gcc for glibc builds.
Review URL: http://codereview.chromium.org/8184010
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6879
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
kschimpf@google.com [Wed, 5 Oct 2011 18:55:33 +0000 (18:55 +0000)]
Turn on reporting of error messages when applying x86 validators verbosely.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2337
Review URL: http://codereview.chromium.org/8137009
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6847
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
pdox@google.com [Sat, 17 Sep 2011 02:24:06 +0000 (02:24 +0000)]
Add flag pnacl_use_clang=1 to scons, to choose testing pnacl-clang / pnacl-clang++.
Nothing passes yet, because Clang can't build the libraries, since it doesn't recognize the __builtin_nacl_* functions.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=2260
Review URL: http://codereview.chromium.org/7919027
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6715
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
robertm@google.com [Thu, 1 Sep 2011 22:32:48 +0000 (22:32 +0000)]
Reduce scons start-up time by 10% (about 2 secs).
Benchmark: "time ./scons does_not_exist"
Add mechanism to measure time it took to process each *.scons file - this is only enabled with --verbose
Review URL: http://codereview.chromium.org/7827018
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6611
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
bradnelson@google.com [Wed, 31 Aug 2011 19:32:32 +0000 (19:32 +0000)]
Updating nacl to accept the 'linux3' platform.
BUG=None
TEST=None
R=zbehan@google.com
Review URL: http://codereview.chromium.org/7778049
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6601
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Tue, 30 Aug 2011 21:41:42 +0000 (21:41 +0000)]
Remove -fno-builtin from nacl repo scons setup.
Review URL: http://codereview.chromium.org/7799032
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6592
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
sehr@google.com [Mon, 29 Aug 2011 22:12:00 +0000 (22:12 +0000)]
Add thumb2 support to sel_ldr. Continued from issue
http://codereview.chromium.org/7690003/
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/7710015
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6581
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
jvoung@google.com [Thu, 25 Aug 2011 18:24:14 +0000 (18:24 +0000)]
Run check_tls.py on ARM and pnacl x86-32 to ensure that %gs or r9 are not
used directly in the irt.nexe and irt_core.nexe.
BUG= http://code.google.com/p/nativeclient/issues/detail?id=1853
TEST= ./scons --mode=opt-host,nacl -j 10 run_irt_tls_test run_irt_core_tls_test platform=arm bitcode=1 && \
./scons --mode=opt-host,nacl -j 10 run_irt_tls_test run_irt_core_tls_test platform=x86-32 bitcode=1
also run the following to ensure that it does catch cases where tls registers are used:
python src/untrusted/irt/check_tls.py x86-32 objdump scons-out/nacl-x86-32/obj/tests/sysbasic/tls_test.nexe
python src/untrusted/irt/check_tls.py arm toolchain/pnacl_linux_x86_64_newlib/bin/pnacl-dis scons-out/nacl-arm-pnacl/obj/tests/sysbasic/tls_test.nexe
Review URL: http://codereview.chromium.org/7747003
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6548
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Tue, 16 Aug 2011 23:52:57 +0000 (23:52 +0000)]
Fix bit name in naclsdk.py
R=jvoung@googele.com
BUG=
TEST=
Review URL: http://codereview.chromium.org/7621029
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6450
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2
dschuff@google.com [Tue, 16 Aug 2011 23:22:58 +0000 (23:22 +0000)]
Optionally build llc and lli using nacl-gcc
lli currently requires nacl-gcc to build (it uses dlopen and inline asm)
BUG=
TEST=
Review URL: http://codereview.chromium.org/7637024
git-svn-id: svn://svn.chromium.org/native_client/trunk/src/native_client/site_scons@6448
fcba33aa-ac0c-11dd-b9e7-
8d5594d729c2