Skip to contentSkip to conversation

enable hyperthreading tests

PATCH In review Murlin Wenzel 2 participants 4 messages Sep 17, 2010 – Sep 20, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 enable hyperthreading tests

Currently the hyperthreading tests will only run on 32bit (i386) os versions. HT is also supported on x86_64, so I changed defines to allow either os version.

testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c
@@ -233,7 +233,7 @@
 int main(int argc, char *argv[])
 {
 
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
 #else
 	if (!check_ht_capability())
testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c
@@ -17,7 +17,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"
testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c
@@ -22,7 +22,7 @@
 int main(int argc, char *argv[])
 {
 	int ret_val = 1;
-#ifndef __i386__
+#if  (!defined __x86_64__ && !defined __i386__)
 	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
 #else
 		ret_val = check_ht_capability();
testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c +2 -3
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c
@@ -20,7 +20,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"
@@ -47,8 +47,7 @@
 		/*printf("The processor in this system supports HT\n");*/
 		return 1;
 	} else {
-		/*printf("The processor in this system does not support
-		* HT\n");*/
+		/*printf("The processor in this system does not support HT\n");*/
 		return 0;
 	}
 }
testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c
@@ -111,7 +111,7 @@
 {
 	tst_resm(TINFO, "Begin: HyperThreading Interrupt");
 
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
 #else
 	if (!check_ht_capability())
testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c
@@ -60,7 +60,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev

_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

#1 lore raw
Quoted 3 lines · Murlin Wenzel

Currently the hyperthreading tests will only run on 32bit (i386) os versions.  HT is also supported on x86_64, so I changed defines to allow either os version.

Seems sane. Could you change i386 architecture' to x86 architecture' please? Thanks,
-Garrett

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Ltp-list mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

#2 lore raw
Quoted 1 line
Quoted 1 line
Quoted 1 line

On 9/17/2010 at 03:22 PM, in message

<[email protected]>, Garrett Cooper

Quoted 11 lines · <[email protected]> wrote:
Quoted 1 line · Murlin Wenzel

Currently the hyperthreading tests will only run on 32bit (i386) os

versions. HT is also supported on x86_64, so I changed defines to allow either os version.

Quoted 2 lines

Seems sane. Could you change i386 architecture' to x86 architecture' please?
Thanks,
-Garrett

Added requested change from i386 to x86 in print statements.

Murlin

testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c +2 -2
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_affinity/ht_affinity.c
@@ -233,8 +233,8 @@
 int main(int argc, char *argv[])
 {
 
-#ifndef __i386__
-	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
+#if (!defined __i386__ && !defined __x86_64__)
+	tst_brkm(TCONF, NULL, "This test suite can only execute on x86 architecture.");
 #else
 	if (!check_ht_capability())
 	{
testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_affinity/ht_utils.c
@@ -17,7 +17,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"
testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c +2 -2
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_enabled/ht_enabled.c
@@ -22,8 +22,8 @@
 int main(int argc, char *argv[])
 {
 	int ret_val = 1;
-#ifndef __i386__
-	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
+#if  (!defined __x86_64__ && !defined __i386__)
+	tst_brkm(TCONF, NULL, "This test suite can only execute on x86 architecture.");
 #else
 		ret_val = check_ht_capability();
 #endif
testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c +2 -3
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_enabled/ht_utils.c
@@ -20,7 +20,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"
@@ -47,8 +47,7 @@
 		/*printf("The processor in this system supports HT\n");*/
 		return 1;
 	} else {
-		/*printf("The processor in this system does not support
-		* HT\n");*/
+		/*printf("The processor in this system does not support HT\n");*/
 		return 0;
 	}
 }
testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c +2 -2
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_interrupt.c
@@ -111,8 +111,8 @@
 {
 	tst_resm(TINFO, "Begin: HyperThreading Interrupt");
 
-#ifndef __i386__
-	tst_brkm(TCONF, NULL, "This test suite can only execute on i386 architecture.");
+#if (!defined __i386__ && !defined __x86_64__)
+	tst_brkm(TCONF, NULL, "This test suite can only execute on x86 architecture.");
 #else
 	if (!check_ht_capability())
 	{
testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c +1 -1
diff -urN ltp-full-20100831/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c ltp-full-20100831.mrw/testcases/kernel/sched/hyperthreading//ht_interrupt/ht_utils.c
@@ -60,7 +60,7 @@
 
 inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
 {
-#ifndef __i386__
+#if (!defined __i386__ && !defined __x86_64__)
 	return;
 #else
 	__asm__("cpuid"

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev

_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

#3 lore raw
Quoted 8 lines · Murlin Wenzel
Quoted 1 line
Quoted 1 line
Quoted 1 line

On 9/17/2010 at 03:22 PM, in message

<[email protected]>, Garrett Cooper

Quoted 5 lines · <[email protected]> wrote:
Quoted 1 line · Murlin Wenzel

Currently the hyperthreading tests will only run on 32bit (i386) os

versions.  HT is also supported on x86_64, so I changed defines to allow either os version.

Quoted 1 line
Quoted 8 lines
Quoted 6 lines
Quoted 1 line

Seems sane. Could you change i386 architecture' to x86 architecture' please?
Thanks,
-Garrett

Added requested change from i386 to x86 in print statements.

Committed. As a sidenote, it's referred to as SMT, not HTT in
newer processors. SMT is the more generalized implementation of HTT. Cheers,
-Garrett

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Ltp-list mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list