Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
ffc61fb0
Commit
ffc61fb0
authored
Aug 04, 2023
by
Yuchen Pei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-22534 Simplify the workaround for MDEV-31269
Skip exists2in transformations if we are in a ps execution
parent
a87f2277
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
23 deletions
+2
-23
sql/item_subselect.cc
sql/item_subselect.cc
+2
-23
No files found.
sql/item_subselect.cc
View file @
ffc61fb0
...
...
@@ -3096,17 +3096,6 @@ static bool find_inner_outer_equalities(Item **conds,
return
TRUE
;
}
/* Check whether item tree intersects with the free list */
static
bool
intersects_free_list
(
Item
*
item
,
THD
*
thd
)
{
for
(
const
Item
*
to_find
=
thd
->
free_list
;
to_find
;
to_find
=
to_find
->
next
)
if
(
item
->
walk
(
&
Item
::
find_item_processor
,
1
,
(
void
*
)
to_find
))
return
true
;
return
false
;
}
/*
Prepare exists2in / decorrelation transformation
...
...
@@ -3133,19 +3122,9 @@ bool Item_exists_subselect::exists2in_prepare(
DBUG_RETURN
(
TRUE
);
DBUG_ASSERT
(
eqs
.
elements
()
!=
0
);
/*
If we are in a ps/sp execution, check for and skip on
intersection with the temporary free list to avoid 2nd ps execution
segfault
*/
/* A workaround to avoid 2nd ps execution segfault (MDEV-31269). */
if
(
!
thd
->
stmt_arena
->
is_conventional
())
{
for
(
uint
i
=
0
;
i
<
(
uint
)
eqs
.
elements
();
i
++
)
{
if
(
intersects_free_list
(
*
eqs
.
at
(
i
).
eq_ref
,
thd
))
DBUG_RETURN
(
TRUE
);
}
}
/* Determine whether the result will be correlated */
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment