Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tlatools
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
general
stups
tlatools
Commits
f6d8d288
Commit
f6d8d288
authored
10 years ago
by
Markus Alexander Kuppe
Browse files
Options
Downloads
Patches
Plain Diff
[Documentation] Move documentation where it belongs
parent
e5fe78c5
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
tlatools/src/tlc2/tool/fp/LSBDiskFPSet.java
+13
-0
13 additions, 0 deletions
tlatools/src/tlc2/tool/fp/LSBDiskFPSet.java
tlatools/src/tlc2/tool/fp/MSBDiskFPSet.java
+0
-11
0 additions, 11 deletions
tlatools/src/tlc2/tool/fp/MSBDiskFPSet.java
with
13 additions
and
11 deletions
tlatools/src/tlc2/tool/fp/LSBDiskFPSet.java
+
13
−
0
View file @
f6d8d288
...
...
@@ -39,6 +39,19 @@ public class LSBDiskFPSet extends HeapBasedDiskFPSet {
int
cnt
=
(
int
)
tblCnt
.
get
();
Assert
.
check
(
cnt
>
0
,
EC
.
GENERAL
);
// Why not sort this.tbl in-place rather than doubling memory
// requirements by copying to clone array and subsequently sorting it?
// - disk written fps are marked disk written by changing msb to 1
// - next time such a fp from the in-memory this.tlb is converted on the
// fly back and again used to do an in-memory lookup
//
// - this.tbl bucket assignment (hashing) is done on least significant bits,
// which makes in-place sort with overlay index infeasible
// - erasing this.tbl means we will loose the in-memory cache completely until it fills up again
// - new fps overwrite disk flushed fps in-memory
// see MSBDiskFPSet for an implementation that doesn't have the
// requirement to sort in a clone array.
// copy table contents into a buffer array buff; do not erase tbl
buff
=
new
long
[
cnt
];
int
idx
=
0
;
...
...
This diff is collapsed.
Click to expand it.
tlatools/src/tlc2/tool/fp/MSBDiskFPSet.java
+
0
−
11
View file @
f6d8d288
...
...
@@ -71,17 +71,6 @@ public class MSBDiskFPSet extends HeapBasedDiskFPSet {
*/
protected
void
prepareTable
()
{
// Why not sort this.tbl in-place rather than doubling memory
// requirements by copying to clone array and subsequently sorting it?
// - disk written fps are marked disk written by changing msb to 1
// - next time such a fp from the in-memory this.tlb is converted on the
// fly back and again used to do an in-memory lookup
//
// - this.tbl bucket assignment (hashing) is done on least significant bits,
// which makes in-place sort with overlay index infeasible
// - erasing this.tbl means we will loose the in-memory cache completely until it fills up again
// - new fps overwrite disk flushed fps in-memory
// copy table contents into a buffer array buff; do not erase tbl, but 1
// msb of each fp to indicate it has been flushed to disk
for
(
int
j
=
0
;
j
<
tbl
.
length
;
j
++)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment