• Christoph Hellwig's avatar
    xfs: avoid synchronous transaction in xfs_fs_write_inode · 7a36c8a9
    Christoph Hellwig authored
    We already rely on the fact that the sync code will cause a synchronous
    log force later on (currently via xfs_fs_sync_fs -> xfs_quiesce_data ->
    xfs_sync_data), so no need to do this here.  This allows us to avoid
    a lot of synchronous log forces during sync, which pays of especially
    with delayed logging enabled.   Some compilebench numbers that show
    this:
    
    xfs (delayed logging, 256k logbufs)
    ===================================
    
    intial create		  25.94 MB/s	  25.75 MB/s	  25.64 MB/s
    create			   8.54 MB/s	   9.12 MB/s	   9.15 MB/s
    patch			   2.47 MB/s	   2.47 MB/s	   3.17 MB/s
    compile			  29.65 MB/s	  30.51 MB/s	  27.33 MB/s
    clean			  90.92 MB/s	  98.83 MB/s	 128.87 MB/s
    read tree		  11.90 MB/s	  11.84 MB/s	   8.56 MB/s
    read compiled		  28.75 MB/s	  29.96 MB/s	  24.25 MB/s
    delete tree		8.39 seconds	8.12 seconds	8.46 seconds
    delete compiled		8.35 seconds	8.44 seconds	5.11 seconds
    stat tree		6.03 seconds	5.59 seconds	5.19 seconds
    stat compiled tree	9.00 seconds	9.52 seconds	8.49 seconds
    
    xfs + write_inode log_force removal
    ===================================
    intial create		  25.87 MB/s	  25.76 MB/s	  25.87 MB/s
    create			  15.18 MB/s	  14.80 MB/s	  14.94 MB/s
    patch			   3.13 MB/s	   3.14 MB/s	   3.11 MB/s
    compile			  36.74 MB/s	  37.17 MB/s	  36.84 MB/s
    clean			 226.02 MB/s	 222.58 MB/s	 217.94 MB/s
    read tree		  15.14 MB/s	  15.02 MB/s	  15.14 MB/s
    read compiled tree	  29.30 MB/s	  29.31 MB/s	  29.32 MB/s
    delete tree		6.22 seconds	6.14 seconds	6.15 seconds
    delete compiled tree	5.75 seconds	5.92 seconds	5.81 seconds
    stat tree		4.60 seconds	4.51 seconds	4.56 seconds
    stat compiled tree	4.07 seconds	3.87 seconds	3.96 seconds
    
    In addition to that also remove the delwri inode flush that is unessecary
    now that bulkstat is always coherent.
    Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
    Reviewed-by: default avatarDave Chinner <dchinner@redhat.com>
    7a36c8a9
xfs_super.c 48.6 KB