about summary refs log tree commit diff
path: root/src/rt/rust_log.cpp
AgeCommit message (Collapse)AuthorLines
2012-09-21rustc: Shove the address of the box annihilator into the crate mapPatrick Walton-3/+3
2012-09-07gc: Add stack walker for new garbage collector.Elliott Slaughter-31/+25
Safe points are exported in a per-module list via the crate map. A C runtime call walks the crate map at startup and aggregates the list of safe points for the program. Currently the GC doesn't actually deallocate memory on malloc and free. Adding the GC at this stage is primarily of testing value. The GC does attempt to clean up exchange heap and stack-allocated resource on failure. A result of this patch is that the user now needs to be careful about what code they write in destructors, because the GC and/or failure cleanup may need to call destructors. Specifically, calls to malloc are considered unsafe and may result in infinite loops or segfaults.
2012-06-21Tag all remaining FIXMEs with bugs. Install rule in tidy script to enforce this.Graydon Hoare-4/+5
2012-06-21Comments only: annotate FIXMEsTim Chevalier-2/+2
2012-06-04Moved log method into logger class better than scheduler fixes #2495Arkaitz Jimenez-0/+17
2012-04-19add a new runtime log (::rt::box) and make boxed_region use itNiko Matsakis-0/+2
2012-04-03Refactor includes structure, getting rid of rust_internal.hJon Morton-4/+3
Many changes to code structure are included: - removed TIME_SLICE_IN_MS - removed sychronized_indexed_list - removed region_owned - kernel_owned move to kernel.h, task_owned moved to task.h - global configs moved to rust_globals.h - changed #pragma once to standard guard in rust_upcall.h - got rid of memory.h
2012-04-02rt: cleanup passing around of rust_envJon Morton-2/+1
2012-04-01remove rust_srvJon Morton-3/+4
2012-03-31rt: Rename rust_task_thread to rust_sched_loopBrian Anderson-5/+5
This class no longer represents a thread; it just schedules tasks.
2012-02-22rt: Stop logging on the Rust stack. Closes #1478Brian Anderson-0/+4
2012-02-03rt: Rename rust_scheduler to rust_task_threadBrian Anderson-5/+5
2012-01-16use correct size for logging mod_entry state fieldsJyun-Yan You-14/+14
The compiler outputs 32-bit values for these and on 64-bit FreeBSD the runtime was scribbling on some state used by getenv and segfaulting.
2012-01-13rt: Allow console logging to be turned offBrian Anderson-1/+29
2012-01-06add rust_util.h header fileNiko Matsakis-1/+1
2011-12-22Revert all of yesterday's snapshots and try again. Cursed!Graydon Hoare-3/+3
2011-11-07Clean up logging output. Closes #1088Brian Anderson-8/+14
2011-11-02get things checking on ia32Niko Matsakis-1/+1
2011-11-02hack around on makefiles trying to get a 64 bit buildNiko Matsakis-1/+14
right now there are many temporary hacks, search for NDM to find them
2011-08-05Basic async IO module using libuvRob Arnold-0/+2
2011-07-28Remove color-related code from rust_logBrian Anderson-31/+2
This is all dead. If someone decides they want color it will be easy to redo.
2011-06-28Renamed what's left of rust_dom to rust_schedulerEric Holk-5/+5
2011-06-10Make darwin happy.Graydon Hoare-2/+3
2011-06-10Fix printf flags.Graydon Hoare-1/+1
2011-06-10Move rt:: logging namespace to ::rt:: and implement RUST_LOG=? and ↵Graydon Hoare-18/+56
RUST_LOG=::help as synonyms that dump the crate logging map. Also warn when some logging specs don't match.
2011-05-30rt: Use new module syntax for logging rt pseudo-modulesBrian Anderson-12/+12
Now use RUST_LOG=rt::mem instead of RUST_LOG=rt.mem
2011-05-26More delicious dead code removal from runtime, upcalls.Graydon Hoare-2/+0
2011-05-19Remove rustboot-related logging hacksMarijn Haverbeke-6/+1
(Also, feel free to start adding logging to your code. Really. It's fast.)
2011-05-13rt: Don't overshoot the end of the logging spec during parsingBrian Anderson-4/+7
2011-05-13rt: Allocate room for null terminator in logging specBrian Anderson-2/+3
2011-04-19Overhaul logging system in runtimeMarijn Haverbeke-115/+65
See https://github.com/graydon/rust/wiki/Logging-vision The runtime logging categories are now treated in the same way as modules in compiled code. Each domain now has a log_lvl that can be used to restrict the logging from that domain (will be used to allow logging to be restricted to a single domain). Features dropped (can be brought back to life if there is interest): - Logger indentation - Multiple categories per log statement - I possibly broke some of the color code -- it confuses me
2011-04-18Update foregoing patches to leave rust_crate alone.Marijn Haverbeke-0/+83
Apparently it can't live in the main binary, since on non-Linux platforms, dynamics libs won't find symbols in the binary. This removes the crate_map pointer from rust_crate again, and instead passes it as an extra argument to rust_start. Rustboot doesn't pass this argument, but supposedly that's okay as long as we don't actually use it on that platform.
2011-04-18Make log the log level configurable per moduleMarijn Haverbeke-2/+2
This overloads the meaning of RUST_LOG to also allow 'module.submodule' or 'module.somethingelse=2' forms. The first turn on all logging for a module (loglevel 3), the second sets its loglevel to 2. Log levels are: 0: Show only errors 1: Errors and warnings 2: Errors, warnings, and notes 3: Everything, including debug logging Right now, since we only have one 'log' operation, everything happens at level 1 (warning), so the only meaningful thing that can be done with the new RUST_LOG support is disable logging (=0) for some modules. TODOS: * Language support for logging at a specific level * Also add a log level field to tasks, query the current task as well as the current module before logging (log if one of them allows it) * Revise the C logging API to conform to this set-up (globals for per-module log level, query the task level before logging, stop using a global mask) Implementation notes: Crates now contain two extra data structures. A 'module map' that contains names and pointers to the module-log-level globals for each module in the crate that logs, and a 'crate map' that points at the crate's module map, as well as at the crate maps of all external crates it depends on. These are walked by the runtime (in rust_crate.cpp) to set the currect log levels based on RUST_LOG. These module log globals are allocated as-needed whenever a log expression is encountered, and their location is hard-coded into the logging code, which compares the current level to the log statement's level, and skips over all logging code when it is lower.
2011-04-07Move to macro-based logging checks in the C++ codeMarijn Haverbeke-5/+0
No functions should be called for log statements that turn out to be inactive.
2011-01-14Further corrections to the logging layer in runtime.Graydon Hoare-3/+5
2011-01-14Change log buffer butes to a symbolic const in runtime.Graydon Hoare-2/+2
2010-10-11Use new and delete instead of alloca(). Should put out the burning tinderbox.Patrick Walton-2/+3
2010-10-11Try to print backtraces on failurePatrick Walton-17/+25
2010-09-08Tidy up the sync dir, remove dead or mis-designed code in favour of OS ↵Graydon Hoare-2/+1
primitives, switch rust_kernel to use a lock/signal pair and wait rather than spin.
2010-09-07Added a few utility classes, cleaned up the include order of .h files, and ↵Michael Bebenita-1/+2
started to make the Rust kernel own domain message queues rather than the Rust domains themselves.
2010-08-17Add a "special" rust_log flag to be used for debugging in cases where the ↵Michael Bebenita-0/+1
full log output prevents races from occurring.
2010-08-12Add vec debugging utility to _vec module.Roy Frostig-0/+1
2010-08-11Print domain and task names in log prefix.Michael Bebenita-4/+13
2010-08-09Added "none" option to rust_log env string to disable all log output.Michael Bebenita-0/+1
2010-07-28Log a separator when logging switches between threads.Michael Bebenita-2/+7
2010-07-20Back out "::ALL" default logbits.Graydon Hoare-1/+1
2010-07-19Added a message passing system based on lock free queues for inter-thread ↵Michael Bebenita-49/+128
communication. Channels now buffer on the sending side, and no longer require blocking when sending. Lots of other refactoring and bug fixes.
2010-06-28Move more of the GC logic into the runtime.Graydon Hoare-0/+1
2010-06-23Populate tree.Graydon Hoare-0/+117