Commit graph

634 commits

Author SHA1 Message Date
Yoni Fogel
56861ecd78 addresses #918
Merged current progress into trunk

git-svn-id: file:///svn/tokudb@4581 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-17 04:29:17 +00:00
Yoni Fogel
131172d61e Fix issue compiler was warning about in 4577
git-svn-id: file:///svn/tokudb@4580 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-17 04:28:33 +00:00
Rich Prohaska
b526f096a5 fix compiler warning
git-svn-id: file:///svn/tokudb@4577 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-17 00:49:03 +00:00
Yoni Fogel
1ce2303c6b Addresses #918
Merge 'convert to array on rebalancing root' change

git-svn-id: file:///svn/tokudb@4576 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-17 00:01:35 +00:00
Yoni Fogel
88b08c3daf Addresses #918
Merge initial version of array representation of omts into trunk

git-svn-id: file:///svn/tokudb@4574 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-16 23:50:45 +00:00
Rich Prohaska
d79133ce1f bias the pivot search in favor of appends to the dictionary. addresses #896
git-svn-id: file:///svn/tokudb@4546 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-16 01:26:51 +00:00
Bradley C. Kuszmaul
34572ecb9e Oops. Addresses #917.
git-svn-id: file:///svn/tokudb@4545 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-15 20:49:15 +00:00
Bradley C. Kuszmaul
64b08678a1 Tigter code when not filling with zeros. Addresses #917.
git-svn-id: file:///svn/tokudb@4544 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-15 20:44:11 +00:00
Bradley C. Kuszmaul
9ebb4b4080 Don't always fill with zeros. Fixes #917. Gives some speedups on random.
git-svn-id: file:///svn/tokudb@4543 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-15 17:09:14 +00:00
Bradley C. Kuszmaul
10f21e7224 Did a {{{svn merge}}} for {{{tokudb.907}}} and deleted {{{tokudb.907}}}.
Fixes #907.


git-svn-id: file:///svn/tokudb@4524 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-14 01:38:53 +00:00
Yoni Fogel
b4b9748da8 Addresses #912
Use ybt->size field if ybt->ulen field is unset (for DB_DBT_REALLOC).

git-svn-id: file:///svn/tokudb@4505 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-12 23:13:04 +00:00
Yoni Fogel
acf688ef2e Closes #912
toku_db_set_* (the dbt setting functions)
no longer require atomicity for ENOMEM cases.
Also, in the case of realloc, we only alloc new memory if
the new size is larger than the old size, or the new size is less than
half of the old size.

Code has some simplifications due to lesser atomicity requirements.

Modified src/tests/test_db_dbt_mem_behavior.c to take into account
that DB_DBT_REALLOC now uses the ulen field.

git-svn-id: file:///svn/tokudb@4504 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-12 23:07:04 +00:00
Yoni Fogel
fe3cd46d32 Closes #914
git-svn-id: file:///svn/tokudb@4502 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-12 20:46:09 +00:00
Bradley C. Kuszmaul
a4f4d06ff9 Merge the streamlining changes from #911. Fixes #911.
git-svn-id: file:///svn/tokudb@4500 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-12 20:32:22 +00:00
Rich Prohaska
da3b69356c merge branch 838 to main. addresses #838
git-svn-id: file:///svn/tokudb@4493 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-12 13:53:39 +00:00
Bradley C. Kuszmaul
e0d124119b Pack the OMT. Fixes #897.
git-svn-id: file:///svn/tokudb@4421 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-08 16:14:31 +00:00
Bradley C. Kuszmaul
b3f35f217e Hash the cachetable too. Fixes #891.
git-svn-id: file:///svn/tokudb@4388 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-05 22:09:59 +00:00
Rich Prohaska
68e6ca2097 need to update the cursor when skipping provisionally deleted leaf entries. addresses #889
git-svn-id: file:///svn/tokudb@4367 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-04 22:58:07 +00:00
Yoni Fogel
f9982d4a47 Addresses #855, #856.
Bugfix in integration of omt cursors.
We were considering provdel leaf entries as not deleted.

git-svn-id: file:///svn/tokudb@4343 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 16:45:15 +00:00
Yoni Fogel
43d9a43f20 Addresses #855, #856. Reworked ExpectedO(1) cursors to be as close
as possible to the O(logn) cursors.
Semantics are now as close as possible, and may be a little faster now.

git-svn-id: file:///svn/tokudb@4339 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 04:25:28 +00:00
Yoni Fogel
2e01e6d00d Addresses #855, #856. Invalidates cursor on a failed toku_omt_find
git-svn-id: file:///svn/tokudb@4337 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 03:42:56 +00:00
Yoni Fogel
540d7247cd Addresses #855, #856. More 0s become NULLs. toku_omt_cursor_prev checks for index = 0
so that it can invalidate and return EINVAL (since index is unsigned)

git-svn-id: file:///svn/tokudb@4336 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 02:23:39 +00:00
Yoni Fogel
352566ea2f Addresses #855, #856. Standardize index to be unsigned, 32 bits. Used NULL instead of 0
git-svn-id: file:///svn/tokudb@4335 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 02:10:40 +00:00
Bradley C. Kuszmaul
77639084ce Get rid of ERANGE in favor of EINVAL. And fix up a couple of test cases. Addresses #855, #856.
git-svn-id: file:///svn/tokudb@4333 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 01:28:40 +00:00
Bradley C. Kuszmaul
9185a8549b Go to the O(logN)-integer-compare implementation, which is about 5% faster than the O(1) implementation. I cannot explain it. The old stuff is now in {{{omt-with-o1-cursors/}}}. Addresses #855, #856.
git-svn-id: file:///svn/tokudb@4329 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-03 00:50:14 +00:00
Yoni Fogel
eb41b7c0c7 Addresses #855, #856. Integrate OMT cursors with BRT for DB_PREV
git-svn-id: file:///svn/tokudb@4328 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-02 21:35:02 +00:00
Bradley C. Kuszmaul
33d04ef55f Integrate the omtcursors into the BRT. So far only DB_NEXT is implemented. Addresses #855, #856.
git-svn-id: file:///svn/tokudb@4325 c7de825b-a66e-492c-adef-691d508d4ae1
2008-06-02 20:52:12 +00:00
Vincenzo Liberatore
bf759aa8bb Closes #855 Merged back into trunk
git-svn-id: file:///svn/tokudb@4308 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-30 20:41:12 +00:00
Bradley C. Kuszmaul
5952205957 After swapping the order of the free and the alloc of the leafentry, I messed up because the alloc might move the leafentry, so the leafentry's size must be computed while the pointer is still good. Fixes #881.
git-svn-id: file:///svn/tokudb@4276 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 21:38:46 +00:00
Bradley C. Kuszmaul
e7150422f4 Probably repairs #880. Addresses #880.
git-svn-id: file:///svn/tokudb@4259 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 17:12:45 +00:00
Bradley C. Kuszmaul
0c5f094e26 Probably repairs #880. Addresses #880.
git-svn-id: file:///svn/tokudb@4258 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 17:05:03 +00:00
Bradley C. Kuszmaul
d4a80654d1 Simplfy the logic a little. Addresses #880.
git-svn-id: file:///svn/tokudb@4256 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 16:28:37 +00:00
Bradley C. Kuszmaul
8f6bbeb225 Please run the test case under the debugger (compiled with -O0), and then in gdb when it bombs do the following commands.
{{{
(gdb) print original_mp
(gdb) print last_total_size_needed
(gdb) up
(gdb) print *mp
(gdb) where
}}}


Addresses #880. 


git-svn-id: file:///svn/tokudb@4255 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 16:21:28 +00:00
Bradley C. Kuszmaul
e9323991d7 {{{
svn delete tokudb.872
cd tokudb
svn merge -r4187:4233 https://svn.tokutek.com/tokudb/tokudb.872
}}}

Fixes #849, #872.
Addresses #820.


git-svn-id: file:///svn/tokudb@4234 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-29 03:12:59 +00:00
Bradley C. Kuszmaul
c82a8af504 Merge the changes for #871 and #406 into the main line as
{{{
$ cd tokudb; svn merge -r 4179:4181 https://svn.tokutek.com/tokudb/tokudb.871
$ svn delete tokudb.871
}}}

Fixes #871.  Addresses #406.  (Possibly fixes both.)


git-svn-id: file:///svn/tokudb@4182 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-28 01:22:51 +00:00
Bradley C. Kuszmaul
31144bf15b Make the leaf nodes have accurate memory footprint info.
git-svn-id: file:///svn/tokudb@4178 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-27 21:08:31 +00:00
Bradley C. Kuszmaul
7c0038357c A better fix for #865. Fixes #865.
git-svn-id: file:///svn/tokudb@4166 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-27 14:47:23 +00:00
Rich Prohaska
2f35b4cf16 port to i386
git-svn-id: file:///svn/tokudb@4161 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-27 12:26:08 +00:00
Bradley C. Kuszmaul
85d3c99dca Fix #865.
git-svn-id: file:///svn/tokudb@4160 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-27 11:29:33 +00:00
Yoni Fogel
b846ceaa9a Addresses #860
Removed extra mallocs and memcopies for toku_c_get
when the dbts use anything other than DB_DBT_USERMEM

git-svn-id: file:///svn/tokudb@4121 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-24 17:22:14 +00:00
Bradley C. Kuszmaul
fbc83b1cda Hacked fix for #832. Don't promote unless there's space for a max pivot key.
git-svn-id: file:///svn/tokudb@4105 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-23 17:04:21 +00:00
Bradley C. Kuszmaul
f60c54cad0 Fixes #22, #333 and Addresses #818:
* Create an exact bit (#818) for the sums (but doesn't calculate it.)
 * Add magic to the file header (#22)
 * Add per-subdb dupsort flags. (#333).

Did
{{{
$ cd tokudb
$ svn merge -r3990:4094 https://svn.tokutek.com/tokudb/tokudb.818/
$ cd ..
$ svn delete tokudb.818
}}}


git-svn-id: file:///svn/tokudb@4095 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-22 21:28:00 +00:00
Bradley C. Kuszmaul
0534cbcbaa Clean up the debug argument that is passed all around. Addresses #832.
git-svn-id: file:///svn/tokudb@4036 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-20 23:47:39 +00:00
Bradley C. Kuszmaul
b74c85e592 Fix up a fencepost error in the serialization code. Addresses #22.
git-svn-id: file:///svn/tokudb@4035 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-20 21:24:11 +00:00
Rich Prohaska
9d057ea81b enable/disable writing tokulogs. addresses#807
git-svn-id: file:///svn/tokudb@4017 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-19 16:42:38 +00:00
Bradley C. Kuszmaul
52b367b55c Create continuable assertion failures. See #835 for how to use it. Fixes #835.
git-svn-id: file:///svn/tokudb@3989 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-17 01:06:03 +00:00
Bradley C. Kuszmaul
2f47bef9e1 Add information that is printed in the #832 assertion fails. Also, don't actually assert a failure unless the node size got out of control. Thus, if the estimate is too low, print an message and proceed if possible. Addresses #832.
git-svn-id: file:///svn/tokudb@3988 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-17 00:49:13 +00:00
Yoni Fogel
f32fcb751b Closes #777
omt used to replaced libredblack


git-svn-id: file:///svn/tokudb@3986 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-16 20:09:13 +00:00
Bradley C. Kuszmaul
9c26f7c6f8 The proposed fix for #789. Addresses #789.
git-svn-id: file:///svn/tokudb@3983 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-16 18:48:23 +00:00
Bradley C. Kuszmaul
79df5188a4 memcmp does not accurately determine whether two keys are the same. Take out the overactive assertion. Addresses #788, #789.
git-svn-id: file:///svn/tokudb@3980 c7de825b-a66e-492c-adef-691d508d4ae1
2008-05-16 13:47:02 +00:00