Update of bug #18407 (project freeciv): Status: None => Confirmed
_______________________________________________________ Follow-up Comment #2: Reproduced with 2.3.0-RC1 and head of S2_3 (r20165). Looks like it's spending much of its time in auto_arrange_workers() and minions after Brussel / Bruxelles grows from size 50 to size 51. Are megacities like this exposing bad computational complexity in our algorithms? A couple of backtraces from aborting the server during the delay (2.3.0-RC1): #0 0x00007f8b839f1d30 in __sigprocmask (how=<value optimised out>, set=0x7fffad11cd60, oset=0x0) at ../sysdeps/unix/sysv/linux/ia64/sigprocmask.c:43 No locals. #1 0x00007f8b83fe843d in ?? () from /lib/libreadline.so.5 No symbol table info available. #2 <signal handler called> No symbol table info available. #3 0x00000000004ed75a in is_effect_enabled (plist=<value optimised out>, target_player=<value optimised out>, target_city=<value optimised out>, target_building=0x0, target_tile=0x0, target_unittype=0x0, target_output=0x0, target_specialist=0x0, effect_type=<value optimised out>) at effects.c:633 preq_iter = 0x0 #4 is_effect_active (plist=<value optimised out>, target_player=<value optimised out>, target_city=<value optimised out>, target_building=0x0, target_tile=0x0, target_unittype=0x0, target_output=0x0, target_specialist=0x0, effect_type=<value optimised out>) at effects.c:664 No locals. #5 get_target_bonus_effects (plist=<value optimised out>, target_player=<value optimised out>, target_city=<value optimised out>, target_building=0x0, target_tile=0x0, target_unittype=0x0, target_output=0x0, target_specialist=0x0, effect_type=<value optimised out>) at effects.c:784 peffect_iter = 0x30eddb0 peffect = 0x30edf70 bonus = 10 __FUNCTION__ = "get_target_bonus_effects" #6 0x00000000004edd8d in get_city_bonus (pcity=0x30b49b0, effect_type=EFT_MAKE_CONTENT) at effects.c:839 No locals. #7 0x00000000004e7084 in citizen_content_buildings (pcity=0x30b49b0, workers_map=<value optimised out>) at city.c:2385 faces = <value optimised out> #8 city_refresh_from_main_map (pcity=0x30b49b0, workers_map=<value optimised out>) at city.c:2873 No locals. #9 0x000000000059fa78 in apply_solution (state=0x2b85e80, soln=<value optimised out>) at cm.c:706 pcity = 0x30b49b0 i = 27 citizens = 51 city_radius_sq = 1 __FUNCTION__ = "apply_solution" #10 0x000000000059fb66 in evaluate_solution (state=0x2b85e80, soln=0x30edf70) at cm.c:741 pcity = 0x30b49b0 backup = {name = "Brussel / Bruxelles", ' 00' <repeats 28 times>, tile = 0x2b93670, owner = 0x30b3980, original = 0x30b3980, id = 117, size = 51, feel = {{0, 49, 49, 49, 49}, {2, 0, 0, 0, 0}, {47, 0, 0, 0, 0}, {0, 0, 0, 0, 0}}, specialists = {2, 0 <repeats 19 times>}, trade = {0, 0, 0, 0}, trade_value = {0, 0, 0, 0}, tile_cache = 0x31072c0, tile_cache_radius_sq = 20, surplus = {54, 102, 150, 75, 310, 0}, waste = {0, 0, 0, 0, 0, 0}, unhappy_penalty = {0, 0, 0, 0, 0, 0}, prod = {156, 102, 150, 75, 310, 0}, citizen_base = {125, 68, 150, 0, 4, 0}, usage = {102, 0, 0, 0, 0, 0}, bonus = {125, 150, 100, 250, 250, 200}, martial_law = 0, unit_happy_upkeep = 0, food_stock = 520, shield_stock = 177, pollution = 14, illness_trade = 0, turn_plague = 94, city_radius_sq = 20, airlift = 1, did_buy = false, did_sell = false, was_happy = true, anarchy = 0, rapture = 29, turn_founded = 20, turn_last_built = 109, before_change_shields = 177, caravan_shields = 0, disbanded_shields = 0, last_turns_shield_surplus = 102, built = {{ turn = 109}, {turn = 109}, {turn = 109}, {turn = -1}, { turn = -1}, {turn = 109}, {turn = 109}, {turn = 109}, { turn = -1}, {turn = 109}, {turn = 109}, {turn = 109}, { turn = 109}, {turn = -1}, {turn = 109}, {turn = -1}, { turn = 109}, {turn = 109}, {turn = 109}, {turn = 109}, { turn = -1}, {turn = -1}, {turn = -1}, {turn = -1}, {turn = 109}, {turn = -1}, {turn = -1}, {turn = 109}, {turn = -1}, {turn = 109}, {turn = 109}, {turn = 109}, {turn = -1}, {turn = -1}, {turn = -1}, {turn = -1}, {turn = 109}, {turn = 109}, {turn = 109}, { turn = 109}, {turn = -1} <repeats 160 times>}, production = { value = {advance = 0x8dd5a0, govern = 0x8dd5a0, building = 0x8dd5a0, nation = 0x8dd5a0, specialist = 0x8dd5a0, terrain = 0x8dd5a0, uclass = 0x8dd5a0, utype = 0x8dd5a0, base = 0x8dd5a0, ai_level = 9295264, citytile = 9295264, minsize = 9295264, minyear = 9295264, outputtype = 9295264, terrainclass = 9295264, terrainalter = 9295264, special = 9295264, unitclassflag = 9295264, unitflag = 9295264}, kind = VUT_IMPROVEMENT}, changed_from = {value = { advance = 0x8dd5a0, govern = 0x8dd5a0, building = 0x8dd5a0, nation = 0x8dd5a0, specialist = 0x8dd5a0, terrain = 0x8dd5a0, uclass = 0x8dd5a0, utype = 0x8dd5a0, base = 0x8dd5a0, ai_level = 9295264, citytile = 9295264, minsize = 9295264, minyear = 9295264, outputtype = 9295264, terrainclass = 9295264, terrainalter = 9295264, special = 9295264, unitclassflag = 9295264, unitflag = 9295264}, kind = VUT_IMPROVEMENT}, worklist = {length = 8, entries = {{ value = {advance = 0x8ddd20, govern = 0x8ddd20, building = 0x8ddd20, nation = 0x8ddd20, specialist = 0x8ddd20, terrain = 0x8ddd20, uclass = 0x8ddd20, utype = 0x8ddd20, base = 0x8ddd20, ai_level = 9297184, citytile = 9297184, minsize = 9297184, minyear = 9297184, outputtype = 9297184, terrainclass = 9297184, terrainalter = 9297184, special = 9297184, unitclassflag = 9297184, unitflag = 9297184}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8ddea0, govern = 0x8ddea0, building = 0x8ddea0, nation = 0x8ddea0, specialist = 0x8ddea0, terrain = 0x8ddea0, uclass = 0x8ddea0, utype = 0x8ddea0, base = 0x8ddea0, ai_level = 9297568, citytile = 9297568, minsize = 9297568, minyear = 9297568, outputtype = 9297568, terrainclass = 9297568, terrainalter = 9297568, special = 9297568, unitclassflag = 9297568, unitflag = 9297568}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8de620, govern = 0x8de620, building = 0x8de620, nation = 0x8de620, specialist = 0x8de620, terrain = 0x8de620, uclass = 0x8de620, utype = 0x8de620, base = 0x8de620, ai_level = 9299488, citytile = 9299488, minsize = 9299488, minyear = 9299488, outputtype = 9299488, terrainclass = 9299488, terrainalter = 9299488, special = 9299488, unitclassflag = 9299488, unitflag = 9299488}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8def20, govern = 0x8def20, building = 0x8def20, nation = 0x8def20, specialist = 0x8def20, terrain = 0x8def20, uclass = 0x8def20, utype = 0x8def20, base = 0x8def20, ai_level = 9301792, citytile = 9301792, minsize = 9301792, minyear = 9301792, outputtype = 9301792, terrainclass = 9301792, terrainalter = 9301792, special = 9301792, unitclassflag = 9301792, unitflag = 9301792}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8df6a0, govern = 0x8df6a0, building = 0x8df6a0, nation = 0x8df6a0, specialist = 0x8df6a0, terrain = 0x8df6a0, uclass = 0x8df6a0, utype = 0x8df6a0, base = 0x8df6a0, ai_level = 9303712, citytile = 9303712, minsize = 9303712, minyear = 9303712, outputtype = 9303712, terrainclass = 9303712, terrainalter = 9303712, special = 9303712, unitclassflag = 9303712, unitflag = 9303712}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8df820, govern = 0x8df820, building = 0x8df820, nation = 0x8df820, specialist = 0x8df820, terrain = 0x8df820, uclass = 0x8df820, utype = 0x8df820, base = 0x8df820, ai_level = 9304096, citytile = 9304096, minsize = 9304096, minyear = 9304096, outputtype = 9304096, terrainclass = 9304096, terrainalter = 9304096, special = 9304096, unitclassflag = 9304096, unitflag = 9304096}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8dfb20, govern = 0x8dfb20, building = 0x8dfb20, nation = 0x8dfb20, specialist = 0x8dfb20, terrain = 0x8dfb20, uclass = 0x8dfb20, utype = 0x8dfb20, base = 0x8dfb20, ai_level = 9304864, citytile = 9304864, minsize = 9304864, minyear = 9304864, outputtype = 9304864, terrainclass = 9304864, terrainalter = 9304864, special = 9304864, unitclassflag = 9304864, unitflag = 9304864}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x8e26a0, govern = 0x8e26a0, building = 0x8e26a0, nation = 0x8e26a0, specialist = 0x8e26a0, terrain = 0x8e26a0, uclass = 0x8e26a0, utype = 0x8e26a0, base = 0x8e26a0, ai_level = 9316000, citytile = 9316000, minsize = 9316000, minyear = 9316000, outputtype = 9316000, terrainclass = 9316000, terrainalter = 9316000, special = 9316000, unitclassflag = 9316000, unitflag = 9316000}, kind = VUT_IMPROVEMENT}, {value = { advance = 0x0, govern = 0x0, building = 0x0, nation = 0x0, specialist = 0x0, terrain = 0x0, uclass = 0x0, utype = 0x0, base = 0x0, ai_level = 0, citytile = CITYT_CENTER, minsize = 0, minyear = 0, outputtype = O_FOOD, terrainclass = 0, terrainalter = 0, special = 0, unitclassflag = 0, unitflag = 0}, kind = VUT_NONE} <repeats 56 times>}}, city_options = { vec = ""}, units_supported = 0x30dbbe0, {server = { migration_score = 0, mgr_score_calc_turn = -1, illness = 12, steal = 0, workers_frozen = 0, needs_arrange = false, needs_refresh = false, synced = true, debug = false, adv = 0x3100320, ais = {0x3094870}, vision = 0x3100a00}, client = {occupied = false, walls = false, happy = false, unhappy = false, colored = 255, color_index = 12, info_units_supported = 0x1000000000000, info_units_present = 0x3100320, need_updates = 50940016}}} surplus = {24, 78, 118, 112, 235, 42} disorder = false happy = true #11 0x00000000005a1a31 in bb_next (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1659 No locals. #12 cm_find_best_solution (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1809 No locals. #13 cm_query_result (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1834 state = 0x2b85e80 #14 0x00000000004698fe in auto_arrange_workers (pcity=0x30b49b0) at cityturn.c:321 cmp = {minimal_surplus = {1, 1, 0, -1000000000, 0, 0}, require_happy = false, allow_disorder = false, allow_specialists = true, factor = {10, 5, 0, 2, 0, 2}, happy_factor = 0} cmr = 0x30cb400 __FUNCTION__ = "auto_arrange_workers" #15 0x0000000000469c6c in city_increase_size (pcity=0x30b49b0) at cityturn.c:773 new_food = <value optimised out> savings_pct = <value optimised out> have_square = true rapture_grow = <value optimised out> pcenter = 0x2b93670 powner = 0x30b3980 pimprove = <value optimised out> saved_id = 117 __FUNCTION__ = "city_increase_size" #16 0x000000000046b798 in city_populate (pcity=0x30b49b0) at cityturn.c:837 saved_id = 117 __FUNCTION__ = "city_populate" #17 0x000000000046ced1 in update_city_activity (pplayer=<value optimised out>) at cityturn.c:2217 saved_id = <value optimised out> pplayer = 0x30b3980 gov = 0x2afb600 #18 update_city_activities (pplayer=<value optimised out>) at cityturn.c:511 i = 1 r = 0 buf = "] 03`", ' 00' <repeats 13 times>, "] 03` 00 00 00 00 00P"245 00 00 00 00 00n 00 00 00n 00 00 00n 00 00 00 00 00 00 00 60341 21255377177 00 00220341 21255377177 00 00300342 21255377177 00 00 62 00 00 00 00 00 00 00 62 00 00 00 00 00 00 00300342 21255377177 00 00 62 00 00 00 00 00 00 00>251D 00 00 00 00 00370M$203213177 00 00 00 00 00 00 00 00 00234 27] 00 00 00 00 00360 01 00 00 00 00 00 00340377372 02 00 00 00 00200 71v 03", ' 00' <repeats 20 times>, " 20W 16 03 00 00 00 00 01 00 00 00 00 00 00" n = <value optimised out> gold = 42694 __FUNCTION__ = "update_city_activities" #19 0x0000000000407d65 in end_phase () at srv_main.c:1009 MY_i = 0 pplayer = 0x30b3980 __FUNCTION__ = "end_phase" #20 0x000000000040d2a5 in srv_running () at srv_main.c:2180 save_counter = 1 is_new_turn = false eot_timer = 0x2f0a050 need_send_pending_events = true #21 srv_main () at srv_main.c:2564 __FUNCTION__ = "srv_main" #22 0x000000000040466d in main (argc=<value optimised out>, argv=0x7fffad11e4a8) at civserver.c:375 inx = 5 showhelp = false showvers = false option = 0x29e4480 " 01" __FUNCTION__ = "main" #0 0x00007f7225a3dd30 in __sigprocmask (how=<value optimised out>, set=0x7fffb06b0560, oset=0x0) at ../sysdeps/unix/sysv/linux/ia64/sigprocmask.c:43 No locals. #1 0x00007f722603443d in ?? () from /lib/libreadline.so.5 No symbol table info available. #2 <signal handler called> No symbol table info available. #3 0x0000000000403b10 in memcpy@plt () No symbol table info available. #4 0x000000000059f85f in copy_partial_solution (dst=0x7fffb06b0b50, src=0x1757fb8, state=0x1757e80) at /usr/include/bits/string3.h:52 No locals. #5 0x00000000005a03d2 in compute_max_stats_heuristic (state=0x1757e80, oldchoice=<value optimised out>) at cm.c:1514 stat = <value optimised out> solnplus = {worker_counts = 0x1b88090, prereqs_filled = 0x1b88010, production = {86, 46, 99, 30, 14, 3}, idle = 0} #6 choice_is_promising (state=0x1757e80, oldchoice=<value optimised out>) at cm.c:1535 production = {86, 46, 99, 30, 14, 3} beats_best = <value optimised out> #7 next_choice (state=0x1757e80, oldchoice=<value optimised out>) at cm.c:1343 ptype = <value optimised out> newchoice = 0 __FUNCTION__ = "next_choice" #8 0x00000000005a19e5 in take_child_choice (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1407 oldchoice = 14 newchoice = 26 #9 bb_next (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1671 No locals. #10 cm_find_best_solution (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1809 No locals. #11 cm_query_result (pcity=<value optimised out>, param=<value optimised out>, result=<value optimised out>) at cm.c:1834 state = 0x1757e80 #12 0x00000000004698fe in auto_arrange_workers (pcity=0x1c5b1a0) at cityturn.c:321 cmp = {minimal_surplus = {1, 1, 0, -1000000000, 0, 0}, require_happy = false, allow_disorder = false, allow_specialists = true, factor = {10, 5, 0, 2, 0, 2}, happy_factor = 0} cmr = 0x1c9d3f0 __FUNCTION__ = "auto_arrange_workers" #13 0x0000000000469c6c in city_increase_size (pcity=0x1c5b1a0) at cityturn.c:773 new_food = <value optimised out> savings_pct = <value optimised out> have_square = true rapture_grow = <value optimised out> pcenter = 0x1765670 powner = 0x1c85980 pimprove = <value optimised out> saved_id = 117 __FUNCTION__ = "city_increase_size" #14 0x000000000046b798 in city_populate (pcity=0x1c5b1a0) at cityturn.c:837 saved_id = 117 __FUNCTION__ = "city_populate" #15 0x000000000046ced1 in update_city_activity (pplayer=<value optimised out>) at cityturn.c:2217 saved_id = <value optimised out> pplayer = 0x1c85980 gov = 0x16cd600 #16 update_city_activities (pplayer=<value optimised out>) at cityturn.c:511 i = 1 r = 0 buf = "] 03`", ' 00' <repeats 13 times>, "] 03` 00 00 00 00 00P"245 00 00 00 00 00n 00 00 00n 00 00 00n 00 00 00 00 00 00 00300 16k260377177 00 00 17k260377177 00 00P 20k260377177 00 00 62 00 00 00 00 00 00 00 62 00 00 00 00 00 00 00P 20k260377177 00 00 62 00 00 00 00 00 00 00>251D 00 00 00 00 00370r)%r177 00 00 00 00 00 00 00 00 00234 27] 00 00 00 00 00360 01 00 00 00 00 00 00 31270 01 00 00 00 00200Y310 01", ' 00' <repeats 20 times>, " 20w313 01 00 00 00 00 01 00 00 00 00 00 00" n = <value optimised out> gold = 42694 __FUNCTION__ = "update_city_activities" #17 0x0000000000407d65 in end_phase () at srv_main.c:1009 MY_i = 0 pplayer = 0x1c85980 __FUNCTION__ = "end_phase" #18 0x000000000040d2a5 in srv_running () at srv_main.c:2180 save_counter = 1 is_new_turn = false eot_timer = 0x1e9e310 need_send_pending_events = true #19 srv_main () at srv_main.c:2564 __FUNCTION__ = "srv_main" #20 0x000000000040466d in main (argc=<value optimised out>, argv=0x7fffb06b1238) at civserver.c:375 inx = 5 showhelp = false showvers = false option = 0x15b6480 " 01" __FUNCTION__ = "main" _______________________________________________________ Reply to this item at: <http://gna.org/bugs/?18407> _______________________________________________ Message sent via/by Gna! http://gna.org/ _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev