summaryrefslogtreecommitdiff
path: root/include/my_pthread.h
diff options
context:
space:
mode:
authorMichael Widenius <monty@askmonty.org>2009-06-30 00:03:30 +0300
committerMichael Widenius <monty@askmonty.org>2009-06-30 00:03:30 +0300
commitbb55791994deb9677b487e7fcfde233cafbf9dbe (patch)
tree7df90e196dd7fe46b6be0a9e4d334dff7a1d3de9 /include/my_pthread.h
parentc40d85c634a4946d3501b542148d4353fc04fbb4 (diff)
downloadmariadb-git-bb55791994deb9677b487e7fcfde233cafbf9dbe.tar.gz
Added some changes inspired by Zardosht Kasheff:
- Added a handler call (prepare_index_scan()) to inform storage engines that an index scan is about to take place. - Extended the maximun key parts for an index from 16 to 32 - Extended MyISAM and Maria engines to support up to 32 parts Added checks for return value from ha_index_init() include/my_handler.h: Extended number of key parts for MyISAM and Maria from 16 to 32 include/my_pthread.h: Ensure we always have 256M of stack. (Required to be able to handle the current number of keys and key parts in MyISAM) mysql-test/r/create.result: Extended to test for 32 key parts mysql-test/r/myisam.result: Test that we can create 32 but not 33 key parts mysql-test/r/ps_1general.result: Length of ref is now 2048 as we can have more key parts mysql-test/r/ps_2myisam.result: Length of ref is now 2048 as we can have more key parts mysql-test/r/ps_3innodb.result: Length of ref is now 2048 as we can have more key parts mysql-test/r/ps_4heap.result: Length of ref is now 2048 as we can have more key parts mysql-test/r/ps_5merge.result: Length of ref is now 2048 as we can have more key parts mysql-test/suite/maria/r/maria.result: Max key length is now 1208 bytes mysql-test/suite/maria/r/maria3.result: Max key length is now 1208 bytes mysql-test/suite/maria/r/ps_maria.result: Max key length is now 1208 byte mysql-test/t/create.test: Extended to test for 32 key parts mysql-test/t/myisam.test: Test that we can create 32 but not 33 key parts sql/handler.cc: Check return value from ha_index_init() sql/handler.h: Added a handler call (prepare_index_scan()) to inform storage engines that an index scan is about to take place. sql/sql_select.cc: Checks all return values from ha_index_init() Call prepare_index_scan()) to inform storage engines that an index scan is about to take place. Fixed indentation sql/table.cc: Fixed wrong types for key_length (rest of code assumed this was 32 bit) sql/unireg.h: Extended the maximun key parts for an index from 16 to 32 storage/maria/ha_maria.cc: Don't allocate HA_CHECK on the stack in functions where we call repair() as HA_CHECK is HUGE and will overflow stack storage/myisam/ha_myisam.cc: Don't allocate HA_CHECK on the stack in functions where we call repair() as HA_CHECK is HUGE and will overflow stack storage/myisam/mi_check.c: Fixed wrong check if value overflow tests/mysql_client_test.c: Added fflush() to fix output in case of error Fixed wrong check of 'ref' length in EXPLAIN
Diffstat (limited to 'include/my_pthread.h')
-rw-r--r--include/my_pthread.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/include/my_pthread.h b/include/my_pthread.h
index ea5ca8d10d5..5b6888cdf24 100644
--- a/include/my_pthread.h
+++ b/include/my_pthread.h
@@ -687,15 +687,11 @@ extern void my_mutex_end();
#define THREAD_NAME_SIZE 10
#ifndef DEFAULT_THREAD_STACK
-#if SIZEOF_CHARP > 4
/*
- MySQL can survive with 32K, but some glibc libraries require > 128K stack
- To resolve hostnames. Also recursive stored procedures needs stack.
+ We need to have at least 256K stack to handle calls to myisamchk_init()
+ with the current number of keys and key parts.
*/
#define DEFAULT_THREAD_STACK (256*1024L)
-#else
-#define DEFAULT_THREAD_STACK (192*1024)
-#endif
#endif
#define MY_PTHREAD_LOCK_READ 0