aboutsummaryrefslogtreecommitdiffstats
path: root/erts
AgeCommit message (Collapse)Author
2018-08-31Fix an endless rescheduling loop when a process is executing ↵Maxim Fedorov
process_info(self(), ...) It is possible that a process has to yield before completing process_info BIF when it runs out of reductions. If this BIF is called by the process itself, it does not send a signal but executes in the context of a process. If it has to yield, it turns F_LOCAL_SIGS_ONLY flag on, which means new signals won't be fetched from the outer message queue. When the same process needs to execute dirty system code (e.g. dirty GC) it has to be run on a dirty scheduler. However signals enqueued into outer queue cause it to be rescheduled on a normal scheduler. F_LOCAL_SIGS_ONLY prevent outer queue signals delivery, creating an endless rescheduling loop. This commit disengages F_LOCAL_SIG_ONLY if process needs to execute dirty code in order to complete signal delivery and allow process to be moved to dirty run queue.
2018-08-29Update release notesErlang/OTP
2018-08-29Update version numbersErlang/OTP
2018-08-29Merge branch 'rickard/running-trace-fix/ERL-713/OTP-15269' into maint-21Erlang/OTP
* rickard/running-trace-fix/ERL-713/OTP-15269: Fix missing 'in' trace events during 'running' trace
2018-08-27Fix missing 'in' trace events during 'running' traceRickard Green
'in' trace events could be lost when a process had to be rescheduled on another scheduler type (normal <-> dirty).
2018-08-20Fix incoming suspend monitor downRickard Green
An incoming suspend monitor down wasn't handled correct when the local monitor half had been removed with an emulator crash as result.
2018-08-10Update release notesErlang/OTP
2018-08-10Update version numbersErlang/OTP
2018-08-10Merge branch 'rickard/full-cache-nif-env/OTP-15223/ERL-695' into maint-21Erlang/OTP
* rickard/full-cache-nif-env/OTP-15223/ERL-695: Fix caching of NIF environment when executing dirty # Conflicts: # erts/emulator/beam/erl_nif.c
2018-08-10Merge branch 'dotsimon/ref_ordering_bug/OTP-15225' into maint-21Erlang/OTP
* dotsimon/ref_ordering_bug/OTP-15225: Fixed #Ref ordering bug Test #Ref ordering in lists and ets
2018-08-09Fix caching of NIF environment when executing dirtyRickard Green
2018-08-09Fixed #Ref ordering bugSimon Cornish
2018-08-09Test #Ref ordering in lists and etsSimon Cornish
2018-07-18Update release notesErlang/OTP
2018-07-18Update version numbersErlang/OTP
2018-07-18Merge branch 'john/erts/kqueue-stdin-polling/OTP-15169/ERL-647' into maint-21Erlang/OTP
* john/erts/kqueue-stdin-polling/OTP-15169/ERL-647: Use fallback pollset for stdin and friends when using kqueue
2018-07-18Merge branch 'john/erts/fix-literal-map-elements/OTP-15184' into maint-21Erlang/OTP
* john/erts/fix-literal-map-elements/OTP-15184: Fix a rare crash when matching on literal maps
2018-07-18Fix node crash on passing bad arguments to file:read_file_info/2John Högberg
2018-07-13Fix a rare crash when matching on literal mapsJohn Högberg
When matching on a literal map, the map is placed into the general scratch register first. This is fine in isolation, but when the key to be matched was in a Y register it would also be placed in the scratch register, overwriting the map and crashing the emulator.
2018-07-12Update release notesErlang/OTP
2018-07-12Update version numbersErlang/OTP
2018-07-12Merge branch 'john/erts/fix-dirty-reschedule-bug/OTP-15154' into maint-21Erlang/OTP
* john/erts/fix-dirty-reschedule-bug/OTP-15154: Move to a dirty scheduler even when we have pending system tasks
2018-07-12Merge branch 'john/erts/fix-21.0.2-release-notes' into maint-21Erlang/OTP
* john/erts/fix-21.0.2-release-notes: Fix release notes for OTP-21.0.2
2018-07-12Merge branch 'rickard/trace-info-bug/OTP-15183' into maint-21Erlang/OTP
* rickard/trace-info-bug/OTP-15183: Fix trace_info/2
2018-07-12Merge branch 'rickard/corba-build/OTP-15176' into maint-21Erlang/OTP
* rickard/corba-build/OTP-15176: Provide build support for standalone corba repo
2018-07-12Fix trace_info/2Rickard Green
2018-07-12Provide build support for standalone corba repoRickard Green
2018-07-04Fix release notes for OTP-21.0.2John Högberg
The release notes generated in the README and notes.xml were out of sync, and notes.xml erroneously listed a fixed bug as open.
2018-07-03Use fallback pollset for stdin and friends when using kqueueJohn Högberg
This is a hack to make the "noshell" option work; kqueue can poll these fds but will not report EV_EOF. This may be common to all all pipes but we have no way to tell whether an fd is a pipe or not.
2018-06-29Update release notesErlang/OTP
2018-06-29Update version numbersErlang/OTP
2018-06-29Merge branch 'john/erts/inet-drv-race/OTP-15158/ERL-654' into maint-21Erlang/OTP
* john/erts/inet-drv-race/OTP-15158/ERL-654: Fix a race condition when generating async operation ids
2018-06-29Merge branch 'john/erts/merge-OTP-15067' into maint-21Erlang/OTP
* john/erts/merge-OTP-15067: Don't enqueue system tasks if target process is in fail_state Fix erroneous schedule of freed/exiting processes Fix deadlock in run queue evacuation Fix memory leak of processes that died in the run queue
2018-06-28Fix a race condition when generating async operation idsJohn Högberg
The counter used for generating async operation ids was a plain int shared between all ports, which was incorrect but mostly worked fine since the ids only had to be unique on a per-port basis. However, some compilers (notably GCC 8.1.1) generated code that assumed that this value didn't change between reads. Using a shortened version of enq_async_w_tmo as an example: int id = async_ref++; op->id = id; //A return id; //B In GCC 7 and earlier, `async_ref` would be read once and assigned to `id` before being incremented, which kept the values at A and B consistent. In GCC 8, `async_ref` was read when assigned at A and read again at B, and then incremented, which made them inconsistent if we raced with another port. This commit fixes the issue by removing `async_ref` altogether and replacing it with a per-port counter which makes it impossible to race with someone else.
2018-06-27Move to a dirty scheduler even when we have pending system tasksJohn Högberg
When a system task was enqueued on a process between being scheduled and the check altered in this commit, we'd run dirty code on a normal scheduler as the RUNNING_SYS flag wasn't set and we wouldn't migrate back. This change migrates us to a dirty scheduler instead, which will immediately bounce us back to a normal scheduler where RUNNING_SYS will be set appropriately. This is caught fairly reliably by process_SUITE:system_task_failed_enqueue on machines with a lot of cores.
2018-06-25Prepare releaseErlang/OTP
2018-06-21Fix environment case sensitivity issues on WindowsJohn Högberg
2018-06-19Prepare releaseErlang/OTP
2018-06-18Merge remote-tracking branch 'origin/henrik/Update-copyright'Henrik Nord
* origin/henrik/Update-copyright: Update copyright year
2018-06-18Update copyright yearHenrik Nord
2018-06-18Merge branch 'lukas/erts/fix_vxworks_configure'Lukas Larsson
* lukas/erts/fix_vxworks_configure: erts: Fix vxworks configure broken by corba removal
2018-06-18erts: Fix vxworks configure broken by corba removalLukas Larsson
2018-06-18Update preloaded modulesHenrik Nord
2018-06-15Merge branch 'sverker/macos-select-fd-bug'Sverker Eriksson
* sverker/macos-select-fd-bug: erts: Fix MacOS pollset bug
2018-06-14Merge branch 'maint'John Högberg
* maint: Updated OTP version Prepare release Add test case Parse #mc_new_type{}s before definitions_loop/2 erts: Fix race between ets table deletion and auto-unfix
2018-06-14Merge branch 'john/erts/fix-process-schedule-after-free/OTP-15067/ERL-573' ↵John Högberg
into john/erts/merge-OTP-15067
2018-06-14Don't enqueue system tasks if target process is in fail_stateJohn Högberg
The fail state wasn't re-checked in the state change loop; only the FREE state was checked. In addition to that, we would leave the task in the queue when bailing out which could lead to a double-free. This commit backports active_sys_enqueue from master to make it easier to merge onwards.
2018-06-14Fix erroneous schedule of freed/exiting processesJohn Högberg
When scheduled out, the process was never checked for the FREE state before rescheduling, which meant that a system task could sneak in and cause a double-free later on.
2018-06-13erts: Fix MacOS pollset bugSverker Eriksson
that could cause clearing of fd-bits past allocated bit-vectors. Bug introduced on master by 988f5f5e8061ce2e135a314ca782788eda478a06
2018-06-13Merge branch 'sverker/remote-remove-monitor-test'Sverker Eriksson