Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Wed, 4 Apr 2001 15:51:50 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Wed, 4 Apr 2001 15:51:40 -0400 Received: from ns2.servicenet.com.ar ([200.41.148.12]:22535 "EHLO servnet.servicenet.com.ar") by vger.kernel.org with ESMTP id ; Wed, 4 Apr 2001 15:51:25 -0400 Message-ID: From: =?iso-8859-1?Q?Sarda=F1ons=2C_Eliel?= To: linux-kernel@vger.kernel.org Subject: kernel/sched.c questions Date: Wed, 4 Apr 2001 16:52:32 -0300 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.0.1461.28) Content-Type: text/plain; charset="iso-8859-1" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Hello, I would like to know why you put this two functions: void scheduling_functions_start_here(void) { } ... void scheduling_functions_end_here(void) { } why you put 'case TASK_RUNNING' switch (prev->state) { case TASK_INTERRUPTIBLE: if (signal_pending(prev)) { prev->state = TASK_RUNNING; break; } default: del_from_runqueue(prev); case TASK_RUNNING: } and the last one: in the function schedule() you always use this syntax: ----- if (a_condition) goto bebe; bebe_back bebe: do_bebe(); goto bebe_back; ------ why not just doing: if (a_condition) do_bebe(); I know that goto's are better but finaly you are jumping to a function and then calling the function. I think you can improve performance doing this. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/