/*
- * Copyright (c) 2000-2008 Apple Inc. All rights reserved.
+ * Copyright (c) 2000-2009 Apple Inc. All rights reserved.
*
* @APPLE_OSREFERENCE_LICENSE_HEADER_START@
*
#define BASEPRI_FOREGROUND (BASEPRI_DEFAULT + 16) /* 47 */
#define BASEPRI_BACKGROUND (BASEPRI_DEFAULT + 15) /* 46 */
#define BASEPRI_DEFAULT (MAXPRI_USER - (NRQS / 4)) /* 31 */
+#define MAXPRI_THROTTLE (MINPRI + 4) /* 4 */
#define MINPRI_USER MINPRI /* 0 */
/*
extern void compute_stack_target(
void *arg);
+extern void compute_memory_pressure(
+ void *arg);
+
/*
* Conversion factor from usage
* to priority.
*/
#define thread_timer_delta(thread, delta) \
MACRO_BEGIN \
- (delta) = timer_delta(&(thread)->system_timer, \
+ (delta) = (typeof(delta))timer_delta(&(thread)->system_timer, \
&(thread)->system_timer_save); \
- (delta) += timer_delta(&(thread)->user_timer, \
+ (delta) += (typeof(delta))timer_delta(&(thread)->user_timer, \
&(thread)->user_timer_save); \
MACRO_END