Skip to content

Commit

Permalink
[build] Restore _OIL_DEV, which also sets -D GC_TIMING
Browse files Browse the repository at this point in the history
We lost some benchmarks/gc and benchmarks/osh-runtime stats

Also delete bin/osh_cpp
  • Loading branch information
Andy C committed Feb 4, 2023
1 parent bc52b96 commit 0000162
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 20 deletions.
3 changes: 2 additions & 1 deletion NINJA-config.sh
Expand Up @@ -94,7 +94,8 @@ main() {
echo DEPS prebuilt/ninja/*/deps.txt

echo
./configure
# Special _OIL_DEV for -D GC_TIMING
_OIL_DEV=1 ./configure

# Reads the deps.txt files above
PYTHONPATH=. build/ninja_main.py
Expand Down
5 changes: 5 additions & 0 deletions bin/NINJA_subgraph.py
Expand Up @@ -38,6 +38,11 @@ def NinjaGraph(ru):
symlinks = symlinks,
preprocessed = True,
matrix = ninja_lib.COMPILERS_VARIANTS + ninja_lib.GC_PERF_VARIANTS,

# TODO: Rename it to 'oils_for_unix.py' and special binary oils-for-unix
#
# Then you need a symlink 'oils format', 'oils ysh' or something

top_level = True, # _bin/cxx-dbg/oils_cpp
deps = [
'//cpp/core',
Expand Down
6 changes: 0 additions & 6 deletions bin/osh_cpp

This file was deleted.

25 changes: 13 additions & 12 deletions configure
Expand Up @@ -394,30 +394,31 @@ main() {

mkdir -p _build

if ! cc_quiet build/detect-cc.c; then
die "Couldn't compile a basic C program (cc not installed?)"
fi

# Generate configuration for oil-native
local cpp_out=_build/detected-cpp-config.h
detect_cpp > $cpp_out
log "Wrote $cpp_out"

# Fast mode
if test -n "$_OIL_DEV"; then
return
fi

if ! cc_quiet build/detect-cc.c; then
die "Couldn't compile a basic C program (cc not installed?)"
fi

# Legacy OVM build: shell build actions will 'source
# _build/detected-config.sh'. And then adjust flags to compiler (-D, -l,
# etc.)
local sh_out=_build/detected-config.sh
local c_out=_build/detected-config.h

detect_and_echo_vars > $sh_out
detect_c_language > $c_out
log "Wrote $sh_out"

log "Wrote $sh_out and $c_out"
# Fast mode
if test -n "$_OIL_DEV"; then
return
fi

local c_out=_build/detected-config.h
detect_c_language > $c_out
log "Wrote $c_out"
}

if test -z "$_OIL_CONFIGURE_TEST"; then
Expand Down
5 changes: 4 additions & 1 deletion test/stateful.sh
Expand Up @@ -21,7 +21,7 @@ set -o errexit
REPO_ROOT=$(cd $(dirname $0)/.. && pwd) # tsv-lib.sh uses this
readonly REPO_ROOT

source test/common.sh # log
source test/common.sh # log, $OSH
source test/tsv-lib.sh

# This uses ../oil_DEPS/spec-bin/{bash,dash} if they exist
Expand Down Expand Up @@ -174,6 +174,9 @@ EOF
all() {
### Run all tests

# TODO: Run again 'cpp' as well, and write another summary table
local bin_mode=${1:-py}

mkdir -p $BASE_DIR

manifest | xargs -n 1 -- $0 run-file
Expand Down

0 comments on commit 0000162

Please sign in to comment.