Oliver Schneider
27fe263669
Move back to a normal folder structure
2018-05-09 14:37:00 +02:00
Oliver Schneider
4cfa7c5d12
Prep miri repository for rustc merger
2017-07-21 11:30:56 +02:00
Ralf Jung
14cb85809b
always test alignment in memory.rs
2017-07-20 13:24:06 -07:00
Ralf Jung
ede055c2be
fix checking alignment of pointer loads
2017-07-19 20:24:09 -07:00
Ralf Jung
ff9192e346
remove reundant dangling checks in {r,d}eallocate
2017-07-18 13:50:54 -07:00
Oliver Schneider
2e562a4d64
Fix static mutation tests
2017-07-14 17:39:19 +02:00
Oliver Schneider
eb01c3fdd2
Use enum instead of boolean
2017-07-14 17:39:19 +02:00
Oliver Schneider
70a914cd34
Clarify documentation
2017-07-14 17:36:06 +02:00
Oliver Schneider
192da8819f
Ensure that it is not possible to explicitly free stack memory
2017-07-14 17:36:06 +02:00
Oliver Schneider
56d4de303f
Merge pull request #247 from RalfJung/packed
...
Re-do packed memory accesses
2017-07-14 08:30:30 +02:00
Ralf Jung
da5538f0b2
use closures to ensure proper bracketing of unaligned accesses
2017-07-13 10:29:11 -07:00
Ralf Jung
287b6be5ca
track alignment also for ByRef values
2017-07-12 21:06:57 -07:00
Ralf Jung
1fe310c8ba
Memory::read_ptr has to check for relocations on the edges
2017-07-12 19:30:37 -07:00
Ralf Jung
c149c3fc6a
Re-do packed memory accesses
...
We now track in the lvalue whether what we computed is expected to be aligend or not, and then set some state in the memory system accordingly to make it (not) do alignment checks
2017-07-12 17:46:56 -07:00
Oliver Schneider
03f0a88002
Use a wrapper type to differentiate between PrimVal and pointers
2017-07-11 12:28:11 +02:00
Oliver Schneider
2d52054fb2
Rename Pointer to MemoryPointer
2017-07-11 10:32:01 +02:00
Ralf Jung
1cbf5e8962
leave notes regarding possible alignment checks
2017-07-10 18:09:46 -07:00
Ralf Jung
d2cf3d76b9
update for allocator API
2017-07-10 16:15:58 -07:00
Ralf Jung
3c0a6d6922
simplify reallocate
2017-07-10 13:34:54 -07:00
Oliver Schneider
b8bd42e8d4
Merge pull request #234 from RalfJung/reallocate
...
Make Reallocate & Deallocate less permissive
2017-07-05 19:54:54 +02:00
Ralf Jung
4165051073
refine comment explaining the order of checks on deallocate
2017-07-05 10:26:15 -07:00
Oliver Schneider
9a04be974c
Merge pull request #232 from oli-obk/master
...
Only check pointers when dereferencing
2017-07-04 09:50:54 +02:00
Ralf Jung
ffd482e2f5
check the assumptions made by the unchecked_ and copy_nonoverlapping intrinsics
2017-07-03 20:37:38 -07:00
Ralf Jung
440c4778fa
validate size and alignment on reallocate and deallocate
2017-07-03 16:47:58 -07:00
Ralf Jung
dc9f5a205f
properly check for: double-free, use-after-reallocate
2017-07-03 16:12:11 -07:00
Oliver Schneider
823b952ef2
Only check pointers when dereferencing
...
Before we also checked whether pointers had alloc_ids when we created rvalue references
2017-07-03 14:16:11 +02:00
Oliver Schneider
91409f1d76
Code nits
2017-06-28 13:10:50 +02:00
Oliver Schneider
5ee4fdcd15
fetch_tls_dtor "read" an Undef
as nonzero
2017-06-23 13:31:00 +02:00
Oliver Schneider
9be3e9185b
Remove the zst allocation
2017-06-23 12:55:49 +02:00
Ralf Jung
14cb31fb88
permit bit-anding in pointer values below the alignment
...
This makes HashMap work!
2017-06-22 14:46:53 -07:00
Ralf Jung
78aa93fa10
correctly reject functions pointers that had arithmetic done to them
2017-06-21 21:45:51 -07:00
Ralf Jung
7b1582b383
permit integer addition and subtraction on ptr-integers
2017-06-21 21:38:43 -07:00
Oliver Schneider
a82fe9ae0c
Enable more zst writes and reads
2017-06-20 16:26:53 +02:00
Oliver Schneider
ea6f6079ca
Use PrimVal instead of Pointer where applicable
2017-06-20 14:28:19 +02:00
Oliver Schneider
a2baeb516c
Run the tls destructors in the correct order
2017-06-20 14:28:18 +02:00
Oliver Schneider
43afa20dc7
Add pthread docs
2017-06-20 14:28:18 +02:00
Oliver Schneider
fcf495821e
Get rid of the integer allocation
2017-06-20 14:28:18 +02:00
Ralf Jung
e0559a6b24
typos
2017-06-08 10:56:49 -07:00
Ralf Jung
3e1596d8c9
Error out when "primitive MIR math" (as opposed to unchecked intrinsics) overflows
...
Fixes #178
2017-06-07 15:39:44 -07:00
Ralf Jung
e1562fbe71
comments
2017-06-06 10:15:54 -07:00
Ralf Jung
684de68d6c
properly wrap pointer offsets at pointer size
2017-06-05 18:07:26 -07:00
Ralf Jung
7bfda59fe2
don't bother inserting integer relocations into the relocation table
2017-06-05 17:17:16 -07:00
Ralf Jung
2a231d66fc
check bounds when using offset intrinsic or MIR op
2017-06-05 14:27:26 -07:00
Ralf Jung
f39e015163
check for overflow when doing pointer arithmetic
2017-06-05 14:23:35 -07:00
Ralf Jung
6197f4fac9
Permit int->ptr->int roundtrip
2017-06-05 14:23:35 -07:00
Ralf Jung
14b16dcf45
use proper span for TLS dtors; fix some nits
2017-05-30 10:41:38 -07:00
Ralf Jung
a66f359d91
support TLS destructors
2017-05-30 10:41:38 -07:00
Ralf Jung
238211e1b3
implement TLS
2017-05-30 10:41:38 -07:00
Oliver Schneider
538c271e05
Address clippy lints
2017-04-26 12:15:42 +02:00
Oliver Schneider
cb867d250a
Fix casting generic functions to concrete function pointers
2017-03-23 17:57:40 +01:00