05:26 <+bridge> [ddnet] > Hello again! I made map on last version on ddnet, load it into ddnet7, but when I run it in teeworlds, game freezes like windows xp 05:26 <+bridge> [ddnet] https://cdn.discordapp.com/attachments/293493549758939136/701634876624863342/2020-04-20_10-19-52.mp4 05:33 <+bridge> [ddnet] > Hello again! I made map on last version on ddnet, load it into ddnet7-server, but when I run it in teeworlds, game freezes like windows xp 05:33 <+bridge> [ddnet] https://cdn.discordapp.com/attachments/293493549758939136/701634876624863342/2020-04-20_10-19-52.mp4 08:37 <+bridge> [ddnet] @TimiT it looks like your map is missing a background 09:48 <+ChillerDragon> gfx_clear 1 11:01 <+bridge> [ddnet] (to debug it, not to fix it) 11:35 <+bridge> [ddnet] > @TimiT it looks like your map is missing a background 11:35 <+bridge> [ddnet] Yes... i should to use bg? 11:35 <+bridge> [ddnet] > (to debug it, not to fix it) 11:35 <+bridge> [ddnet] Ok :) 16:58 <+bridge> [ddnet] oh, could have asked here first 16:58 <+bridge> [ddnet] @Learath2 https://old.reddit.com/r/C_Programming/comments/g4u9wx/question_about_undefined_behavior_time_travel/ 17:01 <+bridge> [ddnet] why this point trigger hook collusion? 17:01 <+bridge> [ddnet] https://cdn.discordapp.com/attachments/293493549758939136/701809697115603035/2020-04-20-180048-screenshot.png 17:01 <+bridge> [ddnet] check entities 17:03 <+bridge> [ddnet] https://cdn.discordapp.com/attachments/293493549758939136/701810193100439582/2020-04-20-180354-screenshot.png 17:04 <+bridge> [ddnet] @heinrich5991 hm, let me take a look at the standard, I'm not completely sure how allowed that reordering is 17:05 <+Konsti> Hello hello, 17:07 <+bridge> [ddnet] its the 0/0 points of the map i think 17:07 <+bridge> [ddnet] reason enough imo :p 17:08 <+bridge> [ddnet] bug alarm 17:08 <+Konsti> Im trying to toggle super/unsuper on the key o with cfg files like i did with deepfly but it doesnt work because it instantly executes the cfg file which leads to the file that gives o the bind unsuper. Like my cfg file is bind o rcon super; exec 4.cfg. It doesnt give me super but executes the cfg file with bind o rcon unsuper; exec 3.cfg 17:09 <+Konsti> and it keep staying at it, unsuper bind works, super bind doesnt 17:09 <+bridge> [ddnet] keep in mind that yellow hook indicates a hookable tee 17:10 <+bridge> [ddnet] not a hookable block? 17:10 <+bridge> [ddnet] no 17:10 <+bridge> [ddnet] thats the green hookline 17:10 <@heinrich5991> so you have a file 3.cfg with `rcon unsuper; bind o exec 4.cfg` 17:10 <@heinrich5991> and 4.cfg with `rcon super; bind o exec 3.cfg`? 17:10 <@heinrich5991> Konsti: ^ 17:15 <+bridge> [ddnet] @heinrich5991 I can reproduce the compilation on godbolt until clang 3.3 17:15 <+bridge> [ddnet] well until 3.4.1, 3.3 still has it 17:16 <+Konsti> alright ur sentence brought me to the fix. 3.cfg has to be rcon super; bind o exec 4.cfg and 4.cfg has to be rcon unsuper; bind o exec 3.cfg 17:16 <+Konsti> i remember it was not like that on older clients or at least i think so, anyway thanks 17:16 <@heinrich5991> np 17:16 <+Konsti> also send discord unban :) 17:16 <@heinrich5991> I think you were banned for a reason 17:17 <@heinrich5991> or rather for a continued flood of reasons 17:17 <+Konsti> 2 years ago:/ cant even access to my tested map 17:17 <+bridge> [ddnet] I don't see how any of this reordering he talks about is legal 17:18 <+bridge> [ddnet] the last one I kinda see 17:18 <+bridge> [ddnet] as long as the compiler can assume that `write` returns 17:19 <+bridge> [ddnet] (assuming the compiler can look into all functions) 17:19 <+bridge> [ddnet] modifying an object is a side-effect and at sequence points all previous side effects should have taken place and no side effects from the subsequent evaluations shall take place. 17:20 <+bridge> [ddnet] so this is wrong? 17:20 <+bridge> [ddnet] a++; does indeed have a side-effect it modifies an object, and expression evaluations are sequence points 17:20 <+bridge> [ddnet] > The “modifying an object” clause is nonsensical because — in combination with sequence point semantics — it forbids the compiler from eliminating the redundant store when a program contains code like this: 17:20 <+bridge> [ddnet] > 17:20 <+bridge> [ddnet] > x=0; 17:20 <+bridge> [ddnet] > x=0; 17:21 <+bridge> [ddnet] Why? the compiler can deduce that a modification of the object does not happen here 17:22 <+bridge> [ddnet] okay, so this is a misunderstanding of his 17:22 <+bridge> [ddnet] thus the modifying an object clause wouldn't apply here, so it's allowed to optimize this unless x is volatile 17:22 <+bridge> [ddnet] This is just how I understand the standard, you can ask like 50 people and get 50 interpretations 17:22 <+bridge> [ddnet] You should try ##C, there are some standard nutjobs there 17:24 <+bridge> [ddnet] The function thing I'm not sure about, C99 5.1.2.3p2 defines what happens when we know the insides of the function, it doesn't seem to say anything about the default assumption though 17:24 <+bridge> [ddnet] (I think you are right about the miscompilation thing though, seeing how clang 3.3 is the last version that does that) 17:47 <+bridge> [ddnet] @heinrich5991 okay, I'm not quite right. The compiler is allowed to optimize that last thing, but not because of what I said 17:47 <+bridge> [ddnet] It's because the compiler can determine that the side effect is not needed it can optimize out the second expression 18:05 <+bridge> [ddnet] @Learath2 I don't understand 18:05 <+bridge> [ddnet] can you elaborate? 18:09 <+bridge> [ddnet] @heinrich5991 do you have a copy of the standard? C99 5.1.2.3p3 says that an actual implementation need not evaluate an expression if it can determine that it's value is not used and it produces no _needed_ side effects 18:09 <+bridge> [ddnet] The second expressions value is not used, and the compiler determines that it produces no _needed_ side effects 18:09 <+bridge> [ddnet] thus optimizes it out 18:10 <+bridge> [ddnet] @deen b'jao' doesnt work either 18:10 <+bridge> [ddnet] even though there are side-effects as defined by the standard and there is a sequence point 18:14 <+bridge> [ddnet] @Learath2 C_Programming seems to agree with you and me: https://old.reddit.com/r/C_Programming/comments/g4u9wx/question_about_undefined_behavior_time_travel/ 18:21 <+bridge> [ddnet] The reordering thing I am indeed wrong about though, the compiler can re-order as it pleases as long as it satisfies the things in 5.1.2.3p5, e.g. doesn't change "observable behaviour" 18:22 <+bridge> [ddnet] p5 in c99, p6 in c11 18:33 <+bridge> [ddnet] @heinrich5991 and after an extensive discussion, I no longer think that's a miscompilation 18:45 <+bridge> [ddnet] @heinrich5991 why do you think it is? I assumed it was because clang stopped doing it, but that was just a prediction 19:26 <+bridge> [ddnet] @Learath2 I laid out the reasoning in the reddit post 19:27 <+bridge> [ddnet] the compiler cannot create code that aborts when it cannot prove that the code will eventually hit UB 20:43 <+bridge> [ddnet] meh, very hard to think about this, it's not legal in the abstract machine to do the reordering, but the actual implementation is allowed to deviate from that if it can prove that the "observable behaviour" doesn't change, as it doesn't know what bar does, I think the optimization is illegal 20:45 <+bridge> [ddnet] the observable behavior is different for certain kinds of `bar`s 20:45 <+bridge> [ddnet] hence the optimization is illegal 20:47 <+bridge> [ddnet] so the articles premise that "crashes are not side-effecting operations" is wrong 20:47 <+bridge> [ddnet] if the operation couldn't result in an abort, it'd be perfectly legal to reorder the expressions 20:47 <+bridge> [ddnet] yes 22:00 <+bridge> [ddnet] is the premise wrong though, the standard is pretty specific about what has side effects 22:01 <+bridge> [ddnet] I think only because it changes observable behaviour this is illegal :/ 22:16 <+bridge> [ddnet] @Learath2 now dissenting voices on the reddit 22:17 <+bridge> [ddnet] @heinrich5991 you really should try ##C instead, you can read through the backlog with my chat with dho and caze 22:17 <+bridge> [ddnet] do they accept reddit links? 22:17 <+bridge> [ddnet] or should I edit it for them again? 22:18 <+bridge> [ddnet] I don't think there'll be a problem with a reddit link 22:23 <+bridge> [ddnet] Hey, just want to ask if anyone can help me out, I am out of ideas. 22:23 <+bridge> [ddnet] My problem: 22:23 <+bridge> [ddnet] I am about to create a 128 player server for 0.7, so far its working just fine. Now the problem are dummy clients like F-Client or ZillyWoods. 22:23 <+bridge> [ddnet] The current system functions just as the one from 0.6 for vanilla clients: The client gets the closest 64 tees to see. The first problem that occured was that the client info is wrong, because 0.7 doesnt handle the information in the snaps. So I solved that one by sending disconnect/connect packets with correct information but still faked IDs to the client when they come nearby some other tees. 22:23 <+bridge> [ddnet] The client of course only knows about 64 tees, and the server doesnt know if its a dummy or not. The solution would be that the client gets the information of the dummy's closest 64 tees when it switches between them, but that is unfortunately impossible to detect. 22:23 <+bridge> [ddnet] Any ideas? 22:35 < ***> Buffer Playback... 22:35 <+bridge> [22:29:00] [ddnet] that would mean when swapping between dummy and main the other one has wrong information about the tees around 22:35 <+bridge> [22:29:24] [ddnet] you could keep two sets of player information in the client 22:35 <+bridge> [22:29:28] [ddnet] wait 22:35 <+bridge> [22:29:33] [ddnet] one for the dummy and one for the main client 22:35 <+bridge> [22:29:42] [ddnet] thats what i thought too, but i want to make it serverside 22:35 <+bridge> [22:29:59] [ddnet] just in case we get other dummy clients for 0.7 too 22:35 <+bridge> [22:30:33] [ddnet] with that reasoning you could go for full serverside dummies 22:35 <+bridge> [22:30:38] [ddnet] then you wouldn't need a special client 22:35 <+bridge> [22:31:00] [ddnet] that doesnt work in 0.7, as you cant fake client ids anymore 22:35 <+bridge> [22:31:05] [ddnet] they are not in the snaps anymore 22:35 <+bridge> [22:31:18] [ddnet] why do you need client IDs for this? 22:35 <+bridge> [22:31:25] [ddnet] for the information to be correct 22:35 <+bridge> [22:31:42] [ddnet] your own local client id that you have in the client is set when you enter the server 22:35 <+bridge> [22:31:46] [ddnet] and can not be changed 22:35 <+bridge> [22:31:57] [ddnet] but you don't need to change the client ID the client wants 22:35 <+bridge> [22:32:20] [ddnet] you need to change your own one, or at least the information like name and clan 22:35 <+bridge> [22:32:23] [ddnet] that doesnt work either 22:35 <+bridge> [22:33:06] [ddnet] you cannot set m_Local too, that also comes from the connect packet 22:35 <+bridge> [22:33:52] [ddnet] you can pretend the dummy tee is the new main tee and vice versa 22:35 <+bridge> [22:34:23] [ddnet] information of your own tee would be wrong then 22:35 < ***> Playback Complete. 22:35 <+bridge> [ddnet] it would be named `[d] you` then? 22:36 <+bridge> [ddnet] i dont get what exactly you mean, but it would not work 22:36 <+bridge> [ddnet] well, nevermind. but do you know a solution to my initial problem? 22:37 <+bridge> [ddnet] without client modding? 22:43 <+bridge> [ddnet] not entirely without 22:43 <+bridge> [ddnet] unless you match IP addresses 22:43 <+bridge> [ddnet] what would that help 22:44 <+bridge> [ddnet] that's only fuzzy btw 22:44 <+bridge> [ddnet] there are people who have a different IP address than their dummy has 22:45 <+bridge> [ddnet] i dont get how that should help 22:57 <+bridge> [ddnet] @jao weird, works for me 22:57 <+bridge> [ddnet] @jao same error?