projects
/
lttv.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
lttv-gui: load resourceview module
[lttv.git]
/
ltt
/
branches
/
poly
/
lttv
/
lttv
/
state.c
diff --git
a/ltt/branches/poly/lttv/lttv/state.c
b/ltt/branches/poly/lttv/lttv/state.c
index b15c616847d77276471919f5f1808a1eab055ac7..952f6cde9bf866dfc8b349e17d533744b9183e65 100644
(file)
--- a/
ltt/branches/poly/lttv/lttv/state.c
+++ b/
ltt/branches/poly/lttv/lttv/state.c
@@
-1155,7
+1155,7
@@
static void lttv_state_free_cpu_states(LttvCPUState *states, guint n)
guint i;
for(i=0; i<n; i++) {
guint i;
for(i=0; i<n; i++) {
- g_array_free(states[i].mode_stack,
FALS
E);
+ g_array_free(states[i].mode_stack,
TRU
E);
}
g_free(states);
}
g_free(states);
@@
-1184,7
+1184,7
@@
static void lttv_state_free_irq_states(LttvIRQState *states, guint n)
guint i;
for(i=0; i<n; i++) {
guint i;
for(i=0; i<n; i++) {
- g_array_free(states[i].mode_stack,
FALS
E);
+ g_array_free(states[i].mode_stack,
TRU
E);
}
g_free(states);
}
g_free(states);
@@
-1221,7
+1221,7
@@
static LttvBdevState *bdevstate_new(void)
static void bdevstate_free(LttvBdevState *bds)
{
static void bdevstate_free(LttvBdevState *bds)
{
- g_array_free(bds->mode_stack,
FALS
E);
+ g_array_free(bds->mode_stack,
TRU
E);
g_free(bds);
}
g_free(bds);
}
@@
-2139,7
+2139,7
@@
lttv_state_find_process_or_create(LttvTraceState *ts, guint cpu, guint pid,
* the parent waits for its child terminaison, but may also happen in special
* cases in the child's exit : when the parent ignores its children SIGCCHLD or
* has the flag SA_NOCLDWAIT. It can also happen when the child is part
* the parent waits for its child terminaison, but may also happen in special
* cases in the child's exit : when the parent ignores its children SIGCCHLD or
* has the flag SA_NOCLDWAIT. It can also happen when the child is part
- * of a killed thread grou
nd
, but isn't the leader.
+ * of a killed thread grou
p
, but isn't the leader.
*/
static void exit_process(LttvTracefileState *tfs, LttvProcessState *process)
{
*/
static void exit_process(LttvTracefileState *tfs, LttvProcessState *process)
{
@@
-2565,9
+2565,18
@@
static gboolean schedchange(void *hook_data, void *call_data)
/* update cpu status */
if(pid_in == 0)
/* update cpu status */
if(pid_in == 0)
+ /* going to idle task */
cpu_set_base_mode(s->cpu_state, LTTV_CPU_IDLE);
cpu_set_base_mode(s->cpu_state, LTTV_CPU_IDLE);
- else
+ else {
+ /* scheduling a real task.
+ * we must be careful here:
+ * if we just schedule()'ed to a process that is
+ * in a trap, we must put the cpu in trap mode
+ */
cpu_set_base_mode(s->cpu_state, LTTV_CPU_BUSY);
cpu_set_base_mode(s->cpu_state, LTTV_CPU_BUSY);
+ if(process->state->t == LTTV_STATE_TRAP)
+ cpu_push_mode(s->cpu_state, LTTV_CPU_TRAP);
+ }
return FALSE;
}
return FALSE;
}
This page took
0.023259 seconds
and
4
git commands to generate.